Friday, October 14, 2011

Disable the AOT Icon

Restrict AOT icon access on Dynamics AX 

Sometimes we want to restrict the AOT icon access on Dynamics AX, but we don't know how to do it... Is there a way to do this...


In the user group permissions that we want to change, we are going to the 'security' view and setting the 'Development' security key to 'No access'.

Company Specific Color Code

Here, I explain you how to make a form color change in Dynamics AX based on the company that was logged in.


To do this, we need to create/override run() method in SysSetupFormRun class. 


Please refer to the following code sample below. 
It shows how to change the color to red or yellow based on the company KOE or CEE.

public void run()
{
    int red;
    int yellow;
    ;


    super();


    red  = WinAPI::rgb2int(255,0,0);
    yellow  = WinAPI::rgb2int(204,255,0);


    this.design().colorScheme(FormColorScheme::RGB);


    switch(curext())
    {
        case "KOE":
            this.design().backgroundColor(red);
            break;


        case "CEE":
            this.design().backgroundColor(yellow);
            break;


        default:
            break;
    }
}

Speeding Up SQL Operations in AX 2009 Development

The following constructs allow you to insert, update, or delete multiple records. Using these constructs reduces communication between the application and the database, and it increases performance.
Construct
Description
Allows you to insert multiple records in one database trip. Use the RecordSortedList construct when you want a subset of data from a particular table, and when you want it sorted in an order that does not currently exist as an index.
Allows you to insert multiple records in one database trip. Use the RecordInsertList construct when you do not need to sort the data.
Allows you to copy multiple records from one or more tables directly into another table on a single database trip.
Allows you to update multiple rows in a table on a single database trip.
Allows you to delete multiple records from the database on a single database trip.

Run AX as a different user from Windows Explorer

This is something useful for people who have already switched to Windows Server 2008 or Windows Vista / Windows 7.

As you have probably noticed, the Run as... command is not available in these versions of Windows any longer (it's still available from command line, of course, but that's not as user friendly).

As AX users/developers/etc., we all ofter have to log into AX as a different user, for example to verify security settings for a particular AX role being setup.
Having Run as... command in the context menu really saves time here.

So, Microsoft, namely Mark Russinovich, provided a way to return this useful command back into the standard context menu.

You can download and install ShellRunas from technet.

Now, to install it, simply follow the easy instructions below:
  1. Download and unzip ShellRunas by following the link above
  2. Copy ShellRunas.exe to your Windows\System32 folder
  3. Open a Command Line and run the following command: shellrunas /reg
  4. A message box confirming successfull installation should pop up. Click OK
  5. Now, holding down the SHIFT key, right-click the AX icon. You will see a Run as different user... item in the context menu


To uninstall the Shellrunas utility, simply execute the following command from a command prompt: shellrunas /unreg

Data Tracking in AX 2009

How to track records and restore data if by mistaken delete in AX 2009
  • Open Dynamics AX
  •   Go to Administration Module -> Setup -> Database Log
  • Create New-> Next -> Select All Company Accounts -> Next -> Choose Tables to Track
  • Select the Type of Events you want to Track -> Next -> Close
  • Go to Administration -> Setup -> Life Science Electronic Signature Audit Trail
  • Create New audit trailà Select the Table which you want in Audit trailà Save and close the form.
  • Enter the data in the module as per the setting did in the administration module
For Cross Check
  •       Click Administration ModuleàInquiries à Database Logà Here user can See the changes, or Reinsert the data which is by mistaken deleted.  

AX 2012 Pre Release Installation

Following is the Procedure for AX 2012 Installation :-

Setup Prerequistes :-

  • Windows Server 2008 R2 with One Domain Configured
  • SQL Server 2008 (SP2 Optional )
  • Sharepoint Centeral Administration Site (Sharepoint 2010)
  • Microsoft Office 2010 (For Office Add ins)

1) Run Setup.exe

2) Click on Install (Microsoft Dynamics AX Components)

3) Click next on the Welcome page

4) Click on "I Accept the licence terms "

5) Choose you Option

6) Select your Update Choice


7) Application File Location


8) Click on Install


9)

10) Choose Your Installation Type (In this Demo I used Single Computer Installation)


11)
12) Check All Configure CheckBoxes

13)
14)
15)
16) 17) If some errors occurs (Click on the Link under Download Column
Download & Install the Update )


18) Type your AOS Service Account Details (You should use the Dedicated account)

In this Installation we are using the Administrator Account.


19)
20) Type your Business Connector Proxy Account Details

21)
22) 23)