ScriptPro Editor This topic is for use by scriptwriters who are using ScriptPro Editor to create custom scripts for their agencies. Agents can go to Using ScriptPro Scripts for more information about using custom or standard scripts within Travelport Smartpoint. |
Edit Controls
Edit controls are used to display an input field (a box into which the script user can type data). As scriptwriter, you establish the length of the input field and it cannot be changed by the script user. You also define the type of data which can be input by the script user into an edit control field. The types of data which can be input by the script user are listed below. These same ControlTypes are used with the Listboxes.
Creating an Edit control and associated attributes
-
Right-click anywhere in the background of the dialog box.
-
Select Edit. A new control is added.
-
Adjust the colors and text in the Appearance section. The default color for a Edit box is background white and the font color black. Use the Text box to provide a default value of the variable.
-
Specify the ControlType in the Behavior section. You can place the following three limitations on each of the input fields. Enter a VariableName to be used in your script code.
Criteria
Description
Must-fill
This field can be left blank, but if an entry is made, it must completely fill the input field.
Note: Must-fill can be used in conjunction with Must-enter so that an entry is required and it must completely fill the field.
Must-enter
This field cannot be left blank.
Notes:
- Must-enter cannot be selected when a condition is present.
- Must-enter can be used in conjunction with Must-fill so that an entry is required and it must completely fill the field.
Condition
- If the condition you establish is met, the cursor is allowed in the control and data can be entered.
- If the condition you establish is not met, the cursor is not allowed in the control and data cannot be entered.
Example: ((itin_i=="")AND(itin_ii==""))
If the value of the variable itin_i is null AND the value of the variable itin_ii is null, then data can be entered in the control.
Note: A condition cannot be used if Must-enter has been selected.
Note: See the table in the ListBox control section that describes each of the ControlTypes.
-
Adjust the location and size in the Layout section.
Edit Date Controls
Edit date controls are used to display an input field (a box into which the script user can type dates). As scriptwriter, you establish the date format. There are four date formats which can be input by the script user and the format will be added as a watermark in the edit control.
Creating an Edit Date control and associated attributes
-
Right click anywhere in the background of the dialog box.
-
Select Edit Date. A new control is added.
Note: The default date format is airdate and a calendar icon is displayed. The colors and text in the Appearance section default and should not be changed.
-
The colors and text in the Appearance section default and should not be changed.
-
Use the option Date Format in the Behavior section to set the edit date format. You can place the same three limitations on each of the input fields as used with a regular Edit field. Enter a VariableName to be used in your script code.
-
Check ShowCalendar to display a calendar icon in the input box. Adjust the width of the input field to handle the format selected.
A Calendar will be displayed and a the user can click to find the correct month.