xAPPnow LOW CODE PLATFORM - User Manual 

Still no account yet?

×

UI Layout Element - Visibility

 
Related subfolder of the training project: "Training/UIM/Exercise/Layout"
 
 

Chapter Overview

 
In this training chapter you get familiar with the visibility configuration of Layout UI elements.
 
The visibility can be configured for
 
  • grid row: visible/invisible
  • UI template: editable/readonly, enabled/disabled, visible/invisible
  • UI panel/referenced UI panel: editable/readonly, enabled/disabled, visible/invisible
  • tabbed panel: editable/readonly, enabled/disabled, visible/invisible
 
 
 
 
The following UI page contains a checkbox "Toggle Visible", "Toggle Editable" and "Toggle Enabled", which are mapped to boolean attributes "isVisible", "isEditable"and "isEnabled". Based on the attribute value "TRUE/FALSE" the visibility behaviour of the layout elements of the UI page is configured.
 
 
 
 

Exercise

 
In this exercise you will configure the visibility of Layout UI elements by implementing a UI page as described above.
 
Exercise 1: Create UI Page "Visibility"
 
  • Step 1: Open context menu of folder "Automation/User Interface/Training/Exercise/Layout" in the model tree
  • Step 2: Select menu function "Create Model" to open dialog "Create User Interface Model"
  • Step 3: Enter model name "Visibility" and keep option "Model Type: UI Page"
  • Step 4: Select option "From: UI Page" to open dialog "Select UI Page", open folder "…/Training/UIM/Template/Layout" to select UI page "TMPL_Visibility" with double click then keep default option for "Default Device" and click button "OK" to create the UI page
     
     
 
 
 
 
Exercise 2: Add as CheckBox "Toggle Visible", "Toggle Editable" and "Toggle Enabled"
 
  • Step 1: Drag&Drop attribute "isVisible" from TAB "Data" into third free span of second row.
  • Step 2: Drag&Drop attribute "isEditable" from TAB "Data" into fifth free span of second row.
  • Step 3: Drag&Drop attribute "isEnabled" from TAB "Data" into seventh free span of second row.
     
 
UI Layout Element - Visibility
 
 
 
Exercise 3: Implement "Visible" Script for UI Panel of "BUS - LINE 2"
 
  • Step 1: Select UI panel of "BUS - LINE 2" and open TAB "Implementation" SubTAB "Visibility"
  • Step 2: Select "Script" to handle state "Visible" dynamically
  • Step 3: Enter visibility script:
 
localData.isVisible;
 
 
UI Layout Element - Visibility
 
 
 
Exercise 4: Implement "Editable" Script for Tabbed Panel
 
  • Step 1: Select tabbed panel and open TAB "Implementation" SubTAB "Visibility"
  • Step 2: Select "Script" to handle state "Editable" dynamically
  • Step 3: Enter visibility script:
 
localData.isEditable;
 
 
UI Layout Element - Visibility
 
 
 
 
Exercise 5: Implement "Enabled" Script for Button Template
 
  • Step 1: Select button template and open TAB "Implementation" SubTAB "Visibility"
  • Step 2: Select "Script" to handle state "Enabled" dynamically
  • Step 3: Enter visibility script:
 
localData.isEnabled;
 
 
UI Layout Element - Visibility
 
 
 
Exercise 6: Implement "Visible" Script for "Footer" Row
 
  • Step 1: Select last row of "Footer" and open TAB "Implementation" SubTAB "Visibility"
  • Step 2: Select "Script" to handle state "Visible" dynamically
  • Step 3: Enter visibility script:
 
localData.isVisible;
 
UI Layout Element - Visibility
 
 
 
Exercise 7: Test the UI Page in the Preview
 
 
 
 
 
1

Select Button Template

1. Select Button Template
Select button template and open TAB "Implementation" SubTAB "Visibility"
2

Select Enable Script

2. Select Enable Script
Select "Script" to handle state "Enabled" dynamically.
3

Enter Script

3. Enter Script
Enter visibility script.
 
 
1

Select Tabbed Panel

1. Select Tabbed Panel
Select tabbed panel and open TAB "Implementation" SubTAB "Visibility"
2

Select Editable Script

2. Select Editable Script
Select "Script" to handle state "Editable" dynamically.
3

Enter Script

3. Enter Script
Enter visibility script.
1

Select UI Panel

1. Select UI Panel
Select UI panel of "BUS - LINE 2" and open TAB "Implementation" SubTAB "Visibility"
2

Select Visible Script

2. Select Visible Script
Select "Script" to handle state "Visible" dynamically.
3

Enter Script

3. Enter Script
Enter visibility script.
 
1

Select Row

1. Select Row
Select first row and open TAB "Implementation" SubTAB "Visibility"
2

Select Visible Script

2. Select Visible Script
Select "Script" to handle state "Visible" dynamically.
3

Enter Script

3. Enter Script
Enter visibility script.
 
1

Drag&Drop "isVisible"
from Data TAB

1. Drag&Drop "isVisible"
from Data TAB
Drag&Drop attribute "isVisible" from TAB "Data" into third free span of second row.
2

Drag&Drop "isEditable"
from Data TAB

2. Drag&Drop "isEditable"
from Data TAB
Drag&Drop attribute "isEditable" from TAB "Data" into fifth free span of second row.
3

Drag&Drop "isEnabled"
from Data TAB

3. Drag&Drop "isEnabled"
from Data TAB
Drag&Drop attribute "isEnabled" from TAB "Data" into seventh free span of second row.