### Get All Views from a Pane

To get all the Views defined in a Pane, loop over the Pane using For Each.
Hint:
To ensure the right view is selected, set the tag property of the views used.
The tag property could be same and the view name set to lowercase, i.e. Label1 with Tag label1.
Example
Dim pn As Pane
In the Pane Views (=Controls), like Labels, Buttons etc., are defined.
Get the Properties of the Views in the Pane:
For Each n As Node In pn.GetAllViewsRecursive
Log(n.Tag)
Next
Get a View Control (no Tags used):
For Each n As Node In pn.GetAllViewsRecursive
If n Is Label Then
Dim lbl As Label = n
Log(lbl.Text)
End If
If n Is TextField Then
Dim tf As TextField = n
Log(tf.Text)
End If
...
If n Is Button Then ...
If n Is ChoiceBox Then ...
...
Next
Get a View Control (Tags used):
Example for label viewed named Label1.
For Each n As Node In pn.GetAllViewsRecursive
If n Is Label and n.Tag = "label1" Then
Dim lbl As Label = n
Log(lbl.Text)
End If
...
Next

Changed: , Category: Nodes, File: T6C225M1665.htm, ID: 1665