Sunday, September 20, 2009

Search Option in NAV RoleTailored Client



In Microsoft Dynamics NAV 2009 RT Client, it is possible to search for the pages, report and etc… using search box (Shortcut Ctrl+F3).


Friday, September 18, 2009

ENABLING MICROSOFT DYNAMICS NAV SERVER

The Enable for Microsoft Dynamics NAV Server property is new in the Microsoft Dynamics NAV database. When you set this property, you are enabling the functionality of the three-tier architecture.

This gives you access to the special properties and .NET code that are required for computers running Microsoft Dynamics NAV Server to access the database. To set the flag in the Classic client, on the File menu, click Database, and then click New (for a new database) or click Alter (for an existing database). On the Options tab, select Enable for Microsoft Dynamics NAV Server.




Wednesday, September 16, 2009

How to Zoom in NAV 2009 Pages?

In the NAV Classic client forms using Tools-->Zoom (Ctrl+F8) we can see the all the fields and its values.

In the NAV RT Client pages also it is possible to zoom the page using About the Page (Ctrl+Alt+F1) in the top right side of the page.



NOTE: Zooming the Listpart (i.e. subform) is only possible by keeping the cursor in the subform and pressing Ctrl+Alt+F1 Keys. Clicking the About the Page button in the top right side of the page only works for the main forms.



NOTE: In the classic client zoom option display the fields in the same orders  as the fields in the table. In the RT Client zoom option displays first primary key field values and the remaining fields in the alphabetical order and Field ID also displayed...Nice....






 


 


 

How to place the Actions in the pages to new category (NAV 2009)

Instead of placing the actions in the standard categories like New, Process and Report, you can also place your action to your own categories.
The following steps will show the process with an example:

In the object designer, design the page 30 Item Card.

Move to the last blank line in the page.

Go to the Actions using ViewàActions.

Go to the properties of the Action you want to move to the new Category.

Change the following properties:
    • Promoted to Yes
    • PromotedCategory to Category4. Category 4 to 10 are available in the NAV 2009 SP1, other than the standard categories like New, Report and Report.
    • PromotedIsBig to Yes
Go to the Page properties and change the PromotedActionCategoriesML property value like below:
          ENU=New,Process,Report,New Category
First three values should be same like New, Process, Report and from there you can give your own name. If you change these values standard page Categories will be changed.

Run the page in RTC and see the result. You will find a new Category with "New Category" which has your action.

Tuesday, September 15, 2009

Transformging Subforms to Pages

While transforming subforms to the pages using Transformation Tool, TIF information should include main form also. Otherwise the entire menu buttons related to subform will not be moved to pages.

For Example: While transforming Form 46 to page, you should include 42 form also. Otherwise Subform menu's like "Line" will not be moved to the Page 46.

Friday, September 11, 2009

Running Pages & Reports from Run

Running NAV 2009 Pages:

Click Start à Run, and run this:

DynamicsNAV:////runpage?page=90055


 

Running NAV 2009 Reports in RTC;

Click Start à Run, and run this:

Dynamicsnav:////runreport?report=111    


 

Debugging NAV 2009 Pages

Here is the nice post from clausl on how to debug the NAV 2009 pages. Please click the below link

Debugging in NAV 2009

Friday, September 4, 2009

IMPORTOBJECTS

IMPORTOBJECTS Function

Imports one or more objects from either a text file or an .xml file to the application.

IMPORTOBJECTS(FileName[, Format])
Parameters

FileName

Type: Text
The path and name of the file from which you import objects.
Format

Type: Integer
The type of the file from which you import objects. The valid values are 0 and 1. If you specify 0, then the file that you specify in the FileName parameter must be a text file. If you specify 1, then the file that you specify in the FileName parameter must be an .xml file. The default value is 0.
  Remarks

This function is not supported on the RoleTailored client.

This function achieves the same result as the Import item on the File menu in the Classic client.

After you import an object with this function, the object is not compiled. To run the object, you must first manually compile it.

  Example

This example imports an .xml file that contains page objects.

IMPORTOBJECTS('C:\MyExport.txt', 1);

EXPORTOBJECTS

EXPORTOBJECTS Function

Exports one or more objects to either a text file or an .xml file.

EXPORTOBJECTS(FileName, ObjectTableRecord[, Format])
Parameters

FileName

Type: Text
The path and name of the file to which you export objects.
ObjectTableRecord

Type: Record
Specifies a record in the Object table, which is table 2000000001. You can set filters on this record so that the exported objects are also filtered. For more information, see SETFILTER Function (RECORD).
Format

Type: Integer
The type of the file to which you export objects. The valid values are 0 and 1. If you specify 0, then the data is exported in text format. If you specify 1, then the data is exported in XML format. The default value is 0.
  Remarks

This function is not supported on Microsoft Dynamics NAV Server.

This function achieves the same result as the Export item on the File menu in the Classic client.

Exporting to an .xml file is only supported for form or page objects.

  Example

This example filters all reports in the range 50000 to 60000 and then exports the filtered set of reports to a text file. This example requires that you create the following variable.

VariableData typeSubtype
MyFilterRecordObject
MyFilter.SETFILTER(MyFilter.Type,'=Report');
MyFilter.SETFILTER(MyFilter.ID,'%1..%2',50000,60000);
EXPORTOBJECTS('C:\MyExport.txt', MyFilter, 0);

InstructionalTextML Property

Sets the Multilanguage value of the InstructionalText of the object. Use this property as a label.

This property is mainly useful for the ConfirmationDialog type pages. Text specified in this property will be shown when the form is opened.
InstructionalTextML ENU=The quantity on inventory is not sufficient to cover the net change in inventory. Do you still want to record the quantity?

Reference Page # 342


Thursday, September 3, 2009

Page.RUNMODAL

Like in the Standard forms in the NAV 2009, pages also have the option to run it as Page.RUNMODAL.

CLEAR(SomePage)

SomePage.XXX; // any user-defined function

SomePage.SETTABLEVIEW(MyRecord);

SomePage.SETRECORD(MyRecord);

IF SomePage.RUNMODAL = Action::LookupOK THEN

SomePage.GETRECORD(MyRecord)...


If you want to use Page.RUNMODAL, we should be careful about the PageType property of the page.



PageType property should be Worksheet to show the fields in the page in proper order like below.





If the PageType property is not correct, then fields in the page will not be shown in the proper order.



The page shown above is for example purpose.

First, Previous, Next and Last Buttons

In the NAV 2009 Classic client Card forms, it is possible to move between the records using First, Previous, Next and Last buttons.



In the NAV 2009 RoleTailoredClient, first List page will be opened. 

From the List page, Card page can be opened.



The below steps will show how to add First, Previous, Next and Last buttons to the Card page

  • Open the Page 30 in design mode.
  • Go to the Action Designer using ViewàActions and add four Actions like below screenshot.

  • Change the properties of the Actions like shown in the below screenshot. 



Image property should be changed according to the functionality of the button.

Button        Image Property

First            PreviousSet

Previous    PreviousRecord

Next            NextRecord

Last            NextSet


  • Add the code for the new buttons like below screen.

  • Open the Item Card in the RoleTailoredClient.

First: First button will go to the first record in the table.
Previous: Previous button will go to the previous record.
Next: Next button will go to the next record.
Last: Last button will go to the last record in the table.