Wednesday, December 23, 2009

Transformation Tool Issue

There may be possibility in some forms to show the records in bold & colors based on the conditions.

CurrForm."No.".UPDATEFONTBOLD(Condition);

CurrForm."No.".UPDATEFORECOLOR(Condition);

While converting this form to page using Transformation Tool, we will face compilation errors in page because same code is moved into the pages.

After the R&D, I found CodeRules.txt in the Transformation Tool does not have proper rules to transform the above kind of code in to pages.

For Example:

For CurrForm.”No.”.ENABLED(Condition), it is working properly because of the following marked code rules.

  • <find>
  • !currForm!.!var1!.ENABLED :=
  • <declareVariable>
  • !var1!Enable
  • <declareVariableType>
  • Boolean INDATASET
  • <replace>
  • !declaredVariable! :=
  • <moveValueToProperty>
  • !declaredVariable!
  • <movePropertyToControlName>
  • !var1!
  • <moveToProperty>
  • Enabled
  • <comment>

But for Currform.”No.”.UPDATEFONTBOLD(Condition), it is not working because there are not code rules for <moveValueToProperty> <movePropertyToControlName> <moveToProperty>

  • <find>
  • IF !var1! <> !var1!::!var2! THEN
  •   !currForm!.!var3!.UPDATEFONTBOLD := TRUE;
  • <replace>
  • !currForm!.!var3!.UPDATEFONTBOLD := !var1! <> !var1!::!var2!;
  • <find>
  • !currForm!.!var1!.UPDATEFONTBOLD :=
  • <declareVariable>
  • !var1!Emphasize
  • <declareVariableType>
  • Boolean INDATASET
  • <replace>
  • !declaredVariable! :=
  • <comment>

Solution: Either we should change the code rules or modify the page manually.

Wednesday, December 16, 2009

New Report Properties in NAV 2009 SP1

Microsoft Dynamics NAV 2009 (Sp1) reports has new properties to utilize the advantages in the Visual Studio report designing.

Using the following properties, you can design the RTC reports with additional functionalities:

  • EnableHyperlinks (Useful for Drill Down from a Report to a Page functionality)
  • EnableExternalImages
  • EnableExternalAssemblies

Tuesday, December 15, 2009

Reporting for Microsoft Dynamics NAV 2009 (SP1)

Microsoft has provided a very good demo script with scenarios on how to use the new reporting functionality in Microsoft Dynamics NAV 2009.

This documents covers the following functionalities.

  • Format text and add colour
  • Interactively sort table data in a report
  • Add charts
  • Save a report as a PDF or an Excel file
  • Drill down from a report to a page
  • Please click the link to download the Demo Script from the Partner Source.

    Wednesday, December 9, 2009

    How to determine the add-in's public key token

    To register an add-in, you include it in the Client Add-in table in Microsoft Dynamics NAV. To include an add-in in the table, you must provide the Public Key Token.

    1. At a command prompt, change to the directory that contains the sn.exe utility.

    For example, the default directory for Microsoft Visual Studio 2008 is C:\Program Files\Microsoft Visual Studio 8\SDK\v2.0\Bin. (or) the default directory for sn.ext file is C:\Program Files\Microsoft.NET\SDK\v2.0 64bit\Bin.

    2.   Type the following command:

           sn.exe –T <assembly>

    Replace <assembly> with the add-in assembly's path and file name, such as Program Files\Microsoft Dynamics NAV\60\RoleTailored Client\Add-ins\MyCompany.MyProduct.RtcAddins.dll

    3. Press ENTER and not the public token key that is displayed.

    NOTE: Please use semicolons before and after <assembly> value like the following: <assembly>