B4J Question node type

hanyelmehy

Well-Known Member
Licensed User
Longtime User
when use
Code: Copy
For Each n As Node In panel.GetAllViewsRecursive
Code: Copy
If n Is Spinner Then
            
else If n Is TextField Then

End If
spinner are recognized as Spinner and as TextField ?
 
You need to understand that complex nodes like the spinner are not base nodes, they are more like a superimposition of several nodes.
So any text based node will also be recognised as a textfield node, if it contains buttons as the spinner does, it will also be recognised as button, and so on, according to hierarchical position...
 
Upvote 0
Not sure how you are creating the Spinner but I tested this and it is only recognised as a Spinner, not as a Textfield.

The code you posted for the if statement, it is impossible for it to be both. If it's a Spinner it won't even check if it's a Textfield.
 
Upvote 0
Back
Top