Saturday, October 24, 2009

Transformation Tool: Subfrom Menu Items to Pages

Using Transformation Tool it is possible to transform forms to pages in NAV 2009.
Forms like Sales Order, Purchase Order has Line Menu Button in the Main from and Transformation Tool automatically transforms the Line Menu button to the Sub page (ListPart). If the Menu Button has any Menu Items, Transformation Tool will also move the Menu Items to the Sub page.

Logic behind this is,Transformation Tool moves the Menu Item to Sub page if it finds the code like “CurrForm.subform.FORM.FunctionName” in the Onpush of the menu item.
Sales Order—>Line—>Reservation Entries, OnPush trigger has the following code.
CurrForm.SalesLines.FORM.ShowReservationEntries;
image

For example if you want a confirmation message before opening the reservation entries, you can write the code in the function or you can write like below:
IF CONFIRM(Text123,TRUE) THEN
  CurrForm.SalesLines.FORM.ShowReservationEntries;

If the code is like above, Transformation Tool will not move this Reservation Entries menu item to sub page. It will create a new Line menu button in the main page and add the Reservation Entries menu item to that.
image
TIP: If your requirement needs to write code before calling the function in the subform, maintain the code in single line like the following:
IF CONFIRM(Text123,TRUE) THEN CurrForm.SalesLines.FORM.ShowReservationEntries;

Saturday, October 17, 2009

How to change SQL Server default backup location

As part of my job, I need to create databases regularly. Because of this I made a SQL Backup of the database with required objects and necessary setup. When ever I try to create a database, SQL Server is showing the default path of the backups.

It is possible to change the default location of the SQL Server backup files:

If we open the registry using REGEDIT or some other tool and if you navigate to this key:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\MSSQL.1\MSSQLSERVER and change the BackupDirectory value to the required location.

image This solved my problem and saved some time.

Monday, October 12, 2009

ProviderID property to System Parts

Last week after posting the learning on ProviderID property, I am going through the mibuso and found any interesting post related to the ProviderID linking to the System Parts.

I also tried to achieve this, but not able to find any solutions except create a new list page and adding system part to that.

The solution kine has given is working.

-Create a list page based on Sales Line.

-Add only two line. One Container and another Part.

-Change the Parttype to System and SystemPartID to Recordlinks for the part.

-Add the new list page to sale order form as Factbox

-Set the ProviderID and SubFormlink.

This solution is working as temporary.

Friday, October 9, 2009

ProviderID property in NAV 2009

ProviderID property is specifically for the RoleTailored client and not supported in the Classic Client.

This property enables you to create a link from a Repeater or any other type of control to a Factbox. It could also be used to link two FactBoxes. For example, the Sales Order page (42), uses this property to update the Sales Line FactBox by creating a ProviderID link to the SalesLines FastTab.

image

For Example:

If you open the Page 42 in design mode, <Control1906127307> “Sales Line FactBox” control ProviderID value is 58 which is the ID of the SalesLines control in the same page.

image 

That is the reason if you open the Sales Order page in Role Tailored Client, Sales Line Factbox details are updated based on the Sales line you selected.

image

Tuesday, October 6, 2009

Error in NAV 2009 Reporting

Sometimes the following error may occur while designing the reports for RT Client:

“the provided metadata is not valid”

Troubleshooting steps has given below or click the MSDN link.

This error can happen when the following conditions are true:

  • You are using Windows Vista and User Access Control (UAC) is turned on.

  • The executable file that runs the Visual Studio development environment (devenv.exe) is set to run as an administrator.

  • The executable file that runs the Classic client with Microsoft SQL Server (finsql.exe) is not set to run as an administrator.

To resolve this issue, either turn off UAC or set both finsql.exe and devenv.exe to run as an administrator.

To turn off UAC
  1. In Control Panel, select User Accounts.

  2. In User Accounts, click Turn User Account Control On or Off.

  3. Clear the Use User Account Control (UAC) to help protect your computer check box.

To set a program to run as an administrator
  1. Right-click the .exe file, and then select Properties.

  2. In the Properties window, on the Compatibility tab, in the Privilege Level section, select Run this program as an administrator.

Sunday, October 4, 2009

How to become an MVP (Most Valuable Professional)

Here is a nice post from Paul S. Randal on '”How to become an MVP”.

Click the link below:

How to become an MVP

Friday, October 2, 2009

How to Delete Personalization Settings

In the NAV 2009 Role Tailored Client, it is possible to reset the user specified settings, automation decisions and file handling decision using “Delete Personalization Settings” option shown below”

Open the Role Tailored Client.

imageimage

Help regarding the options available in the “Reset User-Specified Settings” form is shown below:

Reset User-Specified Settings

You can personalize the appearance of the RoleTailored client, or decide what to do when the Microsoft Dynamics NAV server requests permission to run unknown software on your computer. The "Reset User-Specified Settings" dialog box gives you the opportunity to undo these personalization's and decisions.

User interface

This category covers changes that modify the appearance of pages in the RoleTailored client. You can specify which elements (such as fact boxes and lists) are shown in a particular page, and also specify the size and position of elements. Click "Reset UI settings" to restore all pages to their original default layout.

Automation objects

An automation object is a software component that can run on a Windows computer. The Microsoft Dynamics NAV server may request to run an automation object on your computer. The first time this happens, the client prompts you for permission to run the object. If you choose “Always allow" or "Never allow,” the client does not prompt you on subsequent occasions when it receives a request to run an object of the same type. You can only revisit this decision by clicking "Reset Automation decisions". The next time the server wants to run an automation object, the client presents the original three choices.

Client file access

The Microsoft Dynamics NAV server may request to run or download a file to your computer. The client offers three choices: Run, Save, or Cancel. It also provides a checkbox, which is selected by default: "Always ask before opening this type of file." If you clear this checkbox, subsequent files of the same type are automatically handled in the same way as the original. You can only then revisit this decision by clicking "Reset file handling decision". The next time the server wants to run or download a file, the client presents the original three choices.