Tuesday, September 8, 2015

Enterprise portal add user or group from other trusted domain

I've been dealing with enterprise portal but using cross domain trust when accessing the enterprise portal website. When adding I tried to add users from other trusted domain the Sharepoint didn't recognize the user I tried to add.
To be able to add other trusted domain you can use below Sharepoint powershell:

STSADM.exe -o setproperty -pn peoplepicker-searchadforests -pv domain:"trustedDomain" -url "http://WebApp/"

After execute the powershell script you will be able to add other domain trusted.

Saturday, August 8, 2015

Export Dynamics AX project from Code

Doing a backup for code can be done in many ways for Dynamics AX, one of it is using the xpo backup.
Below is the sample code to export the Project from x++:

static void ExportProject(Args _args)
    TreeNode            treeNode;
    ProjectNode         projectNode;
    ProjectListNode     projectListNode;
    TreeNodeIterator    it;

    projectListNode = infolog.projectRootNode().AOTfindChild("Shared");
    it = projectListNode.AOTiterator();
    projectNode = projectListNode.AOTfindChild("ALL_CUS");
    treeNode = projectNode;

Thursday, May 21, 2015

SSRS report deployment error

A lot of error can pop up when we deploy the report from AX one of them is "User does not have required permissions. Verify that sufficient permissions have been granted and Windows User Account Control (UAC) restrictions have been addressed.", below are some few place that you can check whether it's already being configured properly:
  • Check whether UAC has been properly set up (disable it for the fastest way)
  • Set respective user as administrator in SSRS server.
  • Check whether respective user has access rights to the SSRS folder
The easiest way to resolve this was to add the respective users to the whole SSRS site as "System admin" role on below location at your SSRS report manager

Wednesday, May 6, 2015

Dynamics AX 2012 SSRS changes not reflected after deployment

After we change the report format at Visual Studio and save it; sometimes when we deploy it from AX client it won't reflect the changes. I've spend quite some times to check why it's not reflected. There are few points that you can check :
  • Check whether Visual Studio properly save the report into AX (most cases)
    • Try to close the "Designer" before saving the report
    • Try to "Add to AOT" not only save
  • Deploy the report directly from Visual Studio (fast workaround)
  • Delete all *.auc file at respective users appData folder
You can always "compare" the report to see the changes.

Wednesday, October 22, 2014

Enterprise portal error in Dynamics AX 2012 R3

Below error was a common error that can happen in Dynamics AX 2012 R3 EP, sometimes we hardly know what was missing or not configured properly:
  • You cannot view data on this page because you are not a registered user in Microsoft Dynamics AX. Contact your Microsoft Dynamics AX administrator.
  • No .NET Business Connector session could be found.

Here are some point that you might need to check
  • Make sure the necessary inbound services was running
  • Make sure BC connector been configured properly

Action that you might try:
  • Re-create the AX user account (delete and import again the AX users)
  • Delete and register/add again the EP website manually (System administration - Setup - Enterprise portal - Web site) [this one will always works for me for the 1st error point]

Tuesday, August 5, 2014

Generate QR barcode in Dynamics AX 2012

I just realize that Dynamics AX 2012 already provided the QR code generation under "C Sharp Projects" nodes

Below is the sample code how to use it

static void QRBarcode(Args _args)
    Microsoft.Dynamics.QRCode.Encoder   qrCode;
    System.String                       netString;
    str                                 tempFileName;
    System.Drawing.Bitmap               netBitmap;
    Bitmap                              imageQR;
    FileIOPermission    perm;  
    BinData             binData;
    container           imageContainer;  
    netString = "TEST";  
    qrCode = new Microsoft.Dynamics.QRCode.Encoder();  
    netBitmap = qrCode.Encode(netString); //encode the string as Bitmap can be used already
    tempFileName = qrCode.GetTempFile(netString); //to get the QR temporary file
    perm = new FileIOPermission(tempFileName,'r');
    binData = new binData();
    imageContainer = binData.getData(); //get the QR code image put inside container so can be stored inside database for storing or reporting purpose



By using the code above we don't need to put another 3rd party software to generate the QR bar code.

In standard AX process this QRCode function has been used to generate the E-Invoice QR bar code.

Sunday, June 22, 2014

Immediately get the table relation in form advance query

Adding a relation in the table sometimes is not enough to get the linkage table in the advance query/filter in the form, we still need to the cross reference update to make the table linkage immediately available at the advance query/filter in the form.