Hi
I'm trying to build a class using BCCodeview.
The class is very simple and contains this hierarchy:
PANEL
BUTTON (view 0)
LABEL (view 1)
BCCCodeview (view 2)
I have created a Show method in which I retrieve the views to use them as needed.
--Classcode Initialize
Could I have some help, please?
I'm trying to build a class using BCCodeview.
The class is very simple and contains this hierarchy:
PANEL
BUTTON (view 0)
LABEL (view 1)
BCCCodeview (view 2)
I have created a Show method in which I retrieve the views to use them as needed.
--Classcode Initialize
B4X:
Sub Class_Globals
Dim vBox As B4XView
End Sub
public Sub show(root As B4XView)
root.AddView(vBox,30dip,100dip,100%x - 60dip,100%y -200dip)
vBox.LoadLayout("mylayout") ' my lyaout contains 1 button, 1 label, 1 BBCodeView
'here i want to retrieve the view that are saved into layout but unsuccessfully
'the code is:
dim btn as Button = Panel.getview(0).As(Button) ' all rights
dim lbl as Label = Panel.getview(1).As(Label) ' all rights
Dim BCCV AS BCCCodeview = Panel.getview(2).As(B4xView).Getview(0).As(BCCCodeview) ' KO this is the problem
'......
End Sub
Could I have some help, please?