An associated pane is a pre-written customized pane that is specifically associated with a SYSPRO key field (i.e. stock code, customer, requisition, etc.).
Some key fields have a small number of associated panes linked to them, whereas others (such as stock code) have many.
The format of associated panes can be:
Listview
Form
Graph
Notepad
Just like customized panes, associated panes can be repositioned elsewhere within the same program, and even float above the program.
An associated pane differs from a customized pane in that when the value of the key field with which it is linked changes, the associated pane automatically refreshes to match (i.e. you do not need to add any code to make this happen). Unlike a customized pane which requires code to be added (to another pane, field, etc.) to cause its OnRefresh event to be fired.
You can add an associated pane to a program as follows:
Right-click on the key field within a form.
Select the Insert Associated Pane function.
Select your choice from the list displayed.
The standard associated panes that ship with SYSPRO are held within the SYSPRO \Base\Samples folder. These should never be modified as they may be overwritten at any time that an upgrade port or later version of SYSPRO is installed.
You can use a modified version of one of these panes by making a copy and modifying the copy. An entry for this copied pane should then be added to the CUSVBC.IMP file so that the new file appears in the list of associated panes when the operator selects to insert one.
File | Description |
---|---|
IMPVBC.IMP |
A list of available associated panes, and the key fields to which they are associated, is held in a file called IMPVBC.IMP that resides in the SYSPRO \Programs folder. This is a text file and contains the following information:
The rows are grouped by key field, and there are two special sections at the end (notepad and customform). Do not change this text file, as it may be overwritten at any time that an upgrade port or later version of SYSPRO is installed. |
Form templates |
These describe associated panes and caption themes and are located in the \Base\Samples folder on the application server. The custom associated panes reside in the same location as the standard ones. The naming convention for the standard associated panes is the text Form, followed by the key field name, followed by a descriptive name for the script, followed by the suffix of .txt. In total, the whole name including the suffix must be 30 characters or less (e.g. the name of the script for the Alternate Suppliers linked to the Stock Code key field is: Form_StockCode_AltSupplier.txt). |
CUSVBC.IMP |
If you wish to add your own associated panes, you can add an entry for this to a file called CUSVBC.IMP which is not shipped with SYSPRO, so will not be overwritten. If the file does not already exist (because you have not added custom associated panes before), the structure of the CUSVBC.IMP file is identical to the IMPVBC.IMP file, so it is easiest to make a copy of this file and edit it. To be used by SYSPRO, the CUSVBC.IMP file must exist in your custom program folder. The location for this is specified against the CUSPRG= entry in the IMPACT.INI file in your SYSPRO Work folder. When a custom associated pane is added using the CUSVBC.IMP file, the associated pane appears at the end of the list of normal associated panes, but before any special associated panes relevant for that key field. The associated panes you create must be saved in the Base\Samples folder on the application server in the format Form_title.txt (where title uniquely identifies the pane). We recommend that you should prefix these titles with usr_ so that they are not overwritten by the standard SYSPRO associated panes. The ID in the CUSVBC.IMP file should start from 910 upwards to avoid conflicting with the standard SYSPRO pane ID's. |
One of the two special associated pane types is the Custom form and this is used to dynamically build and populate a form containing the custom form fields associated with a key field. (The list of custom form fields used by SYSPRO appears in the IMPCFM.IMP file, also in the SYSPRO \Program folder.)
The entries for the Custom form associated panes appear at the end of the IMPVBC.IMP file, under the [customform] section and contain three fields:
Field | Description |
---|---|
Caption | The Caption is the name of the key field with which the pane will be associated. |
Custom code | The Custom code is the internal name that SYSPRO uses for the custom form fields for this key field, and is passed to the associated pane in the CustomFormType variable. |
ID | 901 |
The description and icon information are not required because the description is always Custom form, and the icon is always the same.
The template script used by the Custom form associated panes is called Form_CustomForm.txt and exists in SYSPRO's \Base\Samples folder. The OnLoad function of this script calls the COM Custom Form Query business object passing it the custom form type. The business object returns the list of custom form fields, their types, their size, and if numeric, the number of decimals. The script then builds the form.
The OnRefresh function of the script is passed the custom form type in the CustomFormType variable, and the value of the key field in the RefreshValue variable. The script calls the COM Custom Form Query business object using both these values and it returns the fields and values for this key field. The script then populates the form.
If the operator clicks on one of the values within the Custom form associated pane, the Custom Form Entry screen is displayed. At this point the operator can maintain the custom form values for this key field.
The Form Design button on the toolbar of the Custom Form Entry screen enables you to maintain the configuration of the Custom form fields.
If you make changes to the structure of the Custom form from within the associated pane, you should exit the program containing the associated pane and call up the program again. This is because the associated pane builds the form during its OnLoad function, so any fields added/removed will only reflect the next time that the associated pane's OnLoad function is invoked.
SYSPRO has several places where operators can save notes against key fields, therefore the second type of special associated pane is the generic Notepad. This associated pane enables you to make the notes available wherever the key field exists.
The entries for the Notepad associated pane appear near the end of the IMPVBC.IMP file, under the [notepad] section and contain three fields:
Field | Description |
---|---|
Caption | |
Notepad code | |
ID | 900 |
The description and icon information are not required because the description is always Notepad, and the icon is always the same.
The template script used by the Notepad associated panes is called Form_Notepad.txt and resides in SYSPRO's \Base\Samples folder. As with other associated panes, the key field is passed to the associated pane in the RefreshValue variable. However, in the case of the Notepad associated pane, the RefreshValue variable also contains the type of note (the list of types can be found in the IMPVBC.IMP file under the [notepad] section).
These two pieces of information are both in the RefreshValue variable separated by a comma. The Split command is used to place them into an array so that they can be accessed as separate items. The COM Retrieve RTF Stream business object is called and passed these two values, and the returned information is passed to the RTFText variable so that it can be displayed in the notepad.
The Notepad associated pane is read-only, so it only displays the contents of the .rtf file and does not allow you to change the content. However its toolbar has a button to refresh the data, and a control to change the size of the text.
Some key fields have a Notepad associated pane specifically written for them; such as the Customer Notepad, associated with the Customer field. Most of these allow the operator to modify the content of the notepad, and then save it.
In the case of the Customer Notepad:
Before the pane is refreshed, a check is made to see if the information that is already displayed in the notepad has been changed by the operator. If it has, this is saved before the refresh occurs.
The COM Retrieve RTF Stream business object is used to retrieve the rich text from the .rtf file, and the Notepad Setup Business Object business object is used to write the text to the .rtf file.
The Customer Notepad associated pane also has a toolbar containing commands such as Save, Cut, Copy and Paste, along with the ability to change the font settings.
Operator access to the following activities within this program can be restricted. You configure this using the Operator Maintenance program.
Activity | Description | ||||
---|---|---|---|---|---|
Forms – Customization by operator | Controls whether an operator can access options from the context menu displayed when right-clicking form fields. | ||||
Custom form entry |
Controls whether an operator can capture data for a custom form.
|
||||
Custom form design | Controls whether an operator can change the design of a custom form. |
To reduce the amount of processing required, an associated pane is only refreshed when the value of the key field to which it is associated is changed. This applies even if the associated pane is minimized.
If the other values on the form change, but the key field's value does not, then the associated pane is not refreshed.
This can save time in cases where the associated pane contains a significant amount of information.
An associated pane's title includes the name of the key field with which it is associated.
This prevents confusion if custom form associated panes have been created for multiple key fields.
To make changes to an associated pane, you need to click the Menu button on a pane and select -> from the menu.
Like other customized panes, you can view and edit the VBScript for an associated pane.
The VBScript can be viewed on the VBScript tab or edited using the Edit VBScript button, which takes you to the normal VBScript Editor screen.
When you add an associated pane to an application, information is only displayed in the pane if the operator has access to the business object used by the associated pane.
The business object used is listed in the associated pane's .txt file (located in the \Base\Samples folder).
Locate the XMLOut = CallBO line in the .txt file to determine the business object used. Ensure that the operator's group has access to that business object in the Operator Group Maintenance program.
Associated pane listviews are based on SYSPRO e.net Solutions business objects.
The volume of information available depends on what is returned by the business object. Some return one or two fields for each line, while others return thirty or more.
By default up to nine columns can be viewed. The remaining columns are hidden, but can be viewed using the Field Chooser and dragged onto the pane if required.