B4J Question SplitPane

Discussion in 'B4J Questions' started by moore_it, Mar 26, 2018.

  1. moore_it

    moore_it Active Member Licensed User

    Hi all,
    it's possible to read splitpane nodes ?
    Thanks in advice
     
  2. stevel05

    stevel05 Expert Licensed User

    The simple answer is yes, this code will find and list the panes added and their contents. Getting something useful out of it may be a little more difficult.

    Code:
    Dim SPJO As JavaObject = SplitPane1
        
    Dim L As List = SPJO.RunmethodJO("getChildrenUnmodifiable",Null)
        
    For i = 0 To L.Size - 1
            
    Dim P As Pane = L.Get(i)
            
    Dim PJO As JavaObject = P
            
    Dim L1 As List = PJO.RunMethod("getChildren",Null)
            
    For Each N As Node In L1
                
    If GetType(N) = "anywheresoftware.b4j.objects.PaneWrapper$ConcretePaneWrapper$NonResizePane" Then
                    
    Dim P As Pane = N
                    
    Log(P)
                    
    For Each N As Node In P.GetAllViewsRecursive
                        
    Log("     " & N)
                    
    Next
                
    End If
            
    Next
        
    Next
     
    Peter Simpson and Johan Hormaza like this.
  3. moore_it

    moore_it Active Member Licensed User

    OH YES !
    THANKS STEVEL05
     
Loading...
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice