Include Files

Include files provide a way for developers to group functions so they can be re-used within customizations.

For example, if your site has only one company and you want to customize forms to default the company number and disable input to the company number field, you could perform the following steps to accomplish this:

  1. Write a JavaScript function (for example, initCompanyField).

  2. Save the file in the LAWDIR/persistdata/lawson/portal/scripts folder.

  3. Include the file in your custom form (from the script view).

  4. Implement a FORM_OnInit event that calls your initCompanyField function.

Any files that you store in the location $LAWDIR/persistdata/lawson/portal/content/scripts will be available when you go to the File men and then click Include or when you press the shortcut following keys: Ctrl-Shft-I