How to modify an invoice in Project Accounting so that numbers are converted into words and then displayed at the bottom of the "PA Invoice Format Project Detail Page 1" report


INTRODUCTION


This article describes how to modify an invoice in Project Accounting in Microsoft Dynamics GP so that numbers are converted to words and then displayed at the bottom of the PA Invoice Format Project Detail Page 1 report in Project Accounting.

More Information


You can use a script that contains the RW_ConvertToWordsAndNumbers function to convert the numbers to words and then display the words at the bottom of the report. This function has three parameters:
  • in currency IN_Value: In this parameter, you set the currency value.
  • in string IN_Currency: In this parameter, you set the currency ID for the currency. If you use a functional currency, leave this parameter blank.
  • in integer IN_Mode: In this parameter, any value that is not zero causes the report to use words and numbers instead of only words.

Step 1: Back up and then open the report

  1. Back up the Parept.dic file if you have existing modified Microsoft Dynamics GP reports for Project Accounting. To find the Parept.dic file, follow these steps:
    1. On the Tools menu, point to Setup, point to System, and then click Edit Launch File. If you are prompted, type the system password.
    2. In the Edit Launch File window, click Project Accounting. The location of the Parept.dic file is in the Reports field.
  2. On the Tools menu, point to Customize, and then click Report Writer.
  3. In the Product list, click Project Accounting, and then click OK.
  4. In Report Writer, click Reports.
  5. In the Original Reports list, click PA Invoice Format Project Detail Page 1, and then click Insert.

  6. In the Modified Reports list, click PA Invoice Format Project Detail Page 1, and then click Open.

Step 2: Create a calculated field by using the RW_ConvertToWordsAndNumbers function

  1. In the Report Definition window, click Layout.
  2. In the resource list in the Toolbox window, click Calculated Fields, and then click New.
  3. In the Calculated Field Definition window, specify the following settings:
    • Name: Numbers to Words
    • Result Type: String
    • Expression Type: Calculated
  4. Click the Functions tab, and then click User-Defined.
  5. In the Core list, click System.
  6. In the Function list, click RW_ConvertToWordsAndNumbers, and then click Add.

  7. Click the Fields tab. In the Resources list, click PA Invoice Format HDR TEMP.
  8. In the Field list, click PA Billing Amount, and then click Add.
  9. Click the Constants tab. In the Type list, click String, and then click Add.
  10. In the Type list, click Integer. In the Constant field, type 0, and then click Add.
  11. Click OK.

Step 3: Add the new calculated field to the report layout

  1. In the Toolbox window, drag the Numbers to Words calculated field to the RF section of the report.
  2. If your report is a graphical report, and you want to use the same font in the Numbers to Words calculated field that you use in the other fields in this section, follow these steps:
    1. On the Tools menu, click Drawing Options.
    2. In the Drawing Options window, click 7 in the Font list.

Step 4: Save the report and then exit Report Writer

  1. Close the Report Layout window.
  2. Click Save when you receive the following message:
    "Do you want to save the changes to this report layout?"
  3. In the Report Definition window, click OK.
  4. On the File menu, click Microsoft Dynamics GP.

Step 5: Grant access to the report

Method 1: By using Advanced Security

  1. On the Tools menu, point to Setup, point to System, and then click Advanced Security.

    Note If you are prompted to type the system password, type the system password.
  2. Click View, and then click by Alternate, Modified and Custom.
  3. Expand the following nodes:
    • Project Accounting
    • Reports
    • Project
    • PA Invoice Format Project Detail Page 1
  4. Click Project Accounting (Modified).
  5. Click Apply, and then click OK.



    Note By default, the current user and the current company are selected when you start Advanced Security. Any changes that you make are for the current user and for the current company. However, you can select additional users in the Advanced Security dialog box in the User area. You can select additional companies in the Advanced Security dialog box in the Company area.

Method 2: By using Microsoft Dynamics GP security

  1. On the Tools menu, point to Setup, point to System, and then click Security.

    Note If you are prompted to type the system password, type the system password.
  2. In the User ID list, click the user ID of the user for whom you want to grant access to the report.
  3. In the Product list, click Project Accounting.
  4. In the Type list, click Modified Reports.
  5. In the Series list, click Project.
  6. In the Access List box, double-click PA Invoice Format Project Detail Page 1, and then click OK.

    Note An asterisk appears next to the report name.