Object Purpose
This object is used to display a file's content and, if required, to specify which data (field/record) is viewed on the screen.
It allows for the selection of any displayed records. Should this object be used, the data is stored in a variable to be further processed or stored. See Variable Definition.
Add a file browse to a screen by dragging a "File Browse" object from the top section of the "Control" tab OR the "Style Preview Section" onto the screen.
Step-by-step
1. Drag the object on to the screen:
•If dragged from the "Control" tab, the object will assume the default style. (See Set Default.)
•If dragged from the "Style Preview Section", it will assume that particular style.
2. Now, double-click the selected object on the screen OR the representation in the tree view to open the "Properties" window.
The "General" tab is open by default.
3. In the "File Name" option, select the data file to be displayed from the existing data files in the drop-down list. If you need to edit the selected data file, click . See Editing a Data File.
4. Fill in the "Fields Selection" table:
Field Name column
Define the field position by selecting fields from the drop-down list (this list contains the fields of the previously selected data file).
Length column
Determine the length of each column.
Title column
Define each field name as it will appear on the device's screen. Either maintain the field names from the original file or create new ones.
Store Value column
Define the variable that stores what was selected. To store the information, click the corresponding and create/select a variable. See To Select/Create a Variable.
Use the editing icons to the right of the table to move the rows up and down and to delete or add more rows.
5. As an option, selected records can be stored in a variable. Create/select a variable in the "Store Selected Record (Optional)" option by clicking .
6. Go to the "Query" tab.
7. If required, define a query using "where conditions" in the "Where Clause" table. The Query Assistant will help you define the criteria for the necessary "Where" clause(s) (fields, operand, value type). Use the editing icons to the right of the table to move the rows up and down and to delete or add more rows.
If the query is not needed, continue to step 8.
Double-click the required row or click the corresponding .
The content of the resulting window (Query Assistant)depends on the row selected in the "Where Clause" table (the first row (A) or any of the other rows (B)).
If the Query Assistant is called from A |
If the Query Assistant is called from B |
||
|
|||
|
If needed,check the most adequate parenthesis for your Where clause. |
And Or
|
Check “And” or “Or” and, if needed, the most adequate parenthesis according to your Where clause. |
Table Field |
Select the data file field from the drop-down list or click |
Table Field |
Select the data file field from the drop-down list or click |
Operand |
Select a comparison operand from the drop-down list. |
Operand |
Select a comparison operand from the drop-down list. |
Num. |
Check this option if the Where clause requires numeric values. |
Num. |
Check this option if the Where clause requires numeric values. |
Text |
Check this option if the Where clause requires text values. |
Text |
Check this option if the Where clause requires text values. |
Value/Field |
Click |
Value/ Field |
Click |
Value/Field ... |
Click Its activation depends on the defined “Operand”. |
Value/Field ... |
Click Its activation depends on the defined “Operand”. |
Click |
8. Go to the "Layout" tab.
9. Define the object's style by selecting an option from the drop-down list or by clicking . See Editing and Creating Styles and Editing and Creating the "File Browse" Style.
10. Maintain the given values or specify the object's position/size, within the screen, by providing the "X" and "Y" coordinates as well as "Width" and "Height".
Detail of Position/Size values
11. In the "Name" option, attribute a name to the object. This name is displayed in the tree view.
12. Consider whether or not to check the following options:
"Enable"
Activates the object's input feature.
"Tab Stop"
Must be checked to enable a "Change Tab Order". This provides the possibility to change the order (between data input objects) in which the information is keyed in by the device operator.
"Visible"
Controls the object's visibility in the device's screen.
13. In the "File Browse Layout", define the following options:
"Columns to Lock"
Defines the number of columns to be locked in the table. This locking of columns begins from left to right.
"Header"
This option must be checked to ensure the viewing of the header.
"Footer"
The checking of this option allows for the addition of information at the bottom of the "File Browse" box. Text can be added, syntax commands can be written (consider the list below the box) or selected from the drop-down list.
Use the right click in MCL-Designer's input boxes to access certain features regarding the input box's option as well as general actions such as "Copy"; "Paste"; "Search".
Ex: If you right-click the "Text Data" input box (included in a "Display Text" properties window), you are provided with the "Paste", "Search..." and "Variable Select" options.
If you right-click any other input box, it will provide other possibilities.
14. Go to the "Actions" tab.
Keep in mind there is always a default event (ex: "On Change"; "On Timer"; "On Hotkey"; etc.) attached to the object (in this case, an "On Change" event). If you want the event to trigger an action, you must add processes to it (ex: "Go To"; "Check File"; "Set Focus"; etc.).
15. To edit the default event, double-click the event row ("On Change") OR right-click the event row and select "Edit..." in the resulting menu. Either of these choices opens an "Edit Event" window.
16. Select from the drop-down (B) or (C) list:
A |
This event, performed by the device operator, is the "trigger" that enables an action to advance the application. It cannot be modified. Default event: "On Change" - Is triggered when the operator selects a record or inputs data. |
B |
Provides targets for a "Go to" action (see Working with the Branch Processes Group). After the device operator has fulfilled the "On Change" event, the workflow will proceed to the selected destination. If you want to add processes other than a "Go to", select the <Action> option. |
C |
Provides quick links for a "Go to" action ("Next Screen"; "Exit"; etc.) to be executed when the event is fulfilled. See Detail of a |
Detail of a window
This window is an alternative to the drop-down list of destinations. Select a destination screen or routine within the same program as this object, in the left table. Specify the target even more by selecting from the table to the right. The available options are a consequence of your choice in the left table. If you want to add more processes, select the <Action> option. Finish this operation by clicking |
17. If required, add processes to the default event. See Adding and Editing Processes.
At this stage, the processes are being added to the default event (in this case, an "On Change"). The default event can, however, be ignored/overridden by adding other events (step 19).
This object has predefined local variables (only available in event context). See File Browse's Predefined Local Variables.
18. If there is no need to add more events, click in the "Actions" tab to conclude the operation. If the project requires more events, proceed to step 19.
19. Click (at the bottom of the "Actions" tab) to add a new event.
20. Select one of the available events (D) for this object ("On Timer" or "On Hotkey") and edit it (E or F, G and H).
|
On Timer |
On HotKey |
D |
This event is an exception. The device operator does NOT trigger an action, it is his lack of activity, associated to a predetermined period of time that triggers the action/process. |
This event is used to attribute a keystroke function (in a virtual or hardware keyboard) to the File Browse object. |
E |
Define the target/action to be executed. Select one of the available destinations OR <Action> if you want to add other processes. |
Define the target/action to be executed after the event is triggered. Select one of the available destinations OR <Action> if you want to add other processes. |
F |
This alternative to E provides quick links for a "Go to" action ("Next Screen"; "Exit"; etc.) to be executed when the event is fulfilled. If you want to add other processes, select <Action>. See Detail of a |
This alternative to E provides quick links for a "Go to" action (ex: "Next Screen"; "Exit"; etc.) to be executed when the event is fulfilled. If you want to add other processes, select <Action>. See Detail of a |
G |
Set the time interval, after which, the target/action (E or F) is executed. |
Select the keystroke function that the "File Browse" object will represent. |
H |
If required, check this option to set a repetition cycle. |
N/A |
Detail of a window
This window is an alternative to the drop-down list of destinations. Select a destination screen or routine within the same program as this object, in the left table. Specify the target even more by selecting from the table to the right. The available options are a consequence of your choice in the left table. If you want to add more processes, select the <Action> option. Finish this operation by clicking |
It is possible to add as many of the available events as required by the project. (Repeat steps 19 and 20)
21. Edit the new event(s). Double-click the event row to be edited and open the "Edit Event" window.(Repeat steps 15 and 16)
Ex: The editing of an added "On Hotkey" event.
Define which keystroke function(in a virtual or hardware keyboard) the object represents.
Define the objective/action to be executed after the event is triggered. Select one of the available destinations from the drop-down or list OR <Action> if you want to add other processes.
22. These new events can include processes. See Adding and Editing Processes.
If you have more than one event, remember to select the event row you want to add processes to.
If you use the drag-and-drop method to add processes, make sure to drop the process on the row below the intended event.
Before concluding the addition operation, check the following:
Remember that the "Enable" option (located in the "Layout" tab) must be checked so that the added actions/processes run.
If required, use the icons located on the upper right corner of the "properties" window:
Click this icon to create a new data file. Go to Creating a Data File to see how to fill in the several options available.
Click this icon to open a "Localization" window where you can edit the text element within that object or add translations to it. See Localization.
Click this icon to attach any relevant notes to this object. Enter your text in the resulting window. This information is displayed in the "Developer report". See Report.
23. Click in the "Actions" tab to apply the choices made.
The "File Browse" object has been successfully added to the screen
If any subsequent edition of the object's properties is required, double-click the "File Browse" OR select " 'File Browse Properties" (in its right-click menu) to open the properties window.
If you want to view this object applied within an application, see Sample Applications.
File Browse's Predefined Local Variables
This object has predefined local variables (only available in event context).
Event |
On Change |
|
Variable Name |
L_Control_Name |
L_Record_Number |
Variable ID |
&0a |
&1a |
Description |
Stores the object's name (*) |
Stores selected line nbr |
Event |
On Hotkey |
On Timer |
|
Variable Name |
L_Object_Name |
L_Keycode |
L_Object_Name |
Variable ID |
&0a |
&1a |
&0a |
Description |
Stores the object's name (*) |
Stores defined hotkey code |
Stores the object's name (*) |
* Defined in the object's "properties" window ("Layout" tab).