Sunday, June 22, 2014

How to install a chunk correctly in Microsoft Dynamics GP


Sometimes, the people have asked me why they install the chunk but do not see the changes, or cannot install the chunk due to some error.
When the user installs the chunk, but do not see the changes, this case occurs only when you are installing a new version of the chunk and you have modified report or forms installed.
The first time you install the chunk, only copy the chunk file in the path where GP is installed, but when you install and it is not the first time, is very important to considerate several points. My recommendation for you is to have to follow the next steps:

  1.        We assume the chunk file is called test.cnk, right click on the shortcut of GP, select Open file location or Properties. If you select Properties, click on the Open File location button. This folder is “GP Folder”.
  2.          If you are not sure that the file is installed, you can know it by editing the Dynamics.set file and see what the files are for forms and reports from this product. In the figure below you see the product number and the product name. In this case, the product is installed. If the product is not in this list, the product is not installed, in this case, to go step 5.


   3 .  Look below in the Dynamics.set file, in the same position is the number product and name product in the list, in the same position is the information about the files:

When, you install the chunk, GP creates the product dictionary file in this case test.dic and delete chunk file in this case test.cnk.
If you modify some form for this product, GP creates the form dictionary in the Data folder inside GP folder (in versions before to 9.0 was created in GP folder). The same logic, when you modify any report for this product, then GP creates the report dictionary file in the Data folder inside GP folder.

4.       We Validate if any one of these files exist in Data folder:

In this case, these files do not exist. In the case any file exists (F24917.DIC or R24917.DIC for example), and if you have to keep the modification for the form or report, you have to export the modified report or modified form in one package file, after deleting the F24917.DIC or R24917.DIC file from the Data Folder.

5.       Go to the GP Folder, order the files by name. Delete test.dic file. Sometime exists other file with the same name but the extension vba. The reason is GP adds this extension to all product installed when you used vba in the reports or forms installed. In this case, you have to delete test.vba file, too.
6      Copy the test.cnk file in the GP folder.
7.    Open GP, you receive this message:


8.       Click the Yes Button, you can login whatever user GP, the chunk will be installed correctly.
9.       If you created package in the step 5, you have to import the package, in this case the form dictionary or report dictionary will be created newly.
Other possible reason the chunk is not installed, is when the chunk file is read only, in this case GP cannot delete the file and not receive the message in the step 7 when you open GP, and GP do not create the product dictionary.
Other possible error when install the chunk, is the message “privilege error”, this error occurs when GP program is using for other user in the same host, in this case you have to close all GP sessions in the same host and try again.

In previous versions to GP 9.0 it was necessary to uninstall the product, for that, edit Dynamics.set and delete the lines for the product installed and drop the number at the beginning on the file, but this is not necessary anymore. You can do these steps only if you need to uninstall the product from GP completely.