Dear Mr. Erel
I want to load the layout without animation, can I do this?
Attach my example
I want to load the layout without animation, can I do this?
Attach my example
B4X:
Sub Globals
'These global variables will be redeclared each time the activity is created.
'These variables can only be accessed from this module.
Dim B4XSwitch1 As B4XSwitch
Dim button1 As Button
Dim mTop As Int
End Sub
Sub Activity_Create(FirstTime As Boolean)
'Do not forget to load the layout file created with the visual designer. For example:
'Activity.LoadLayout("Layout1")
'Dim B4XSwitch1 As B4XSwitch
button1.Initialize("button1")
button1.Text="Show Switch"
Activity.AddView(button1,40%x,40%y,20%x,100dip)
mTop=0
End Sub
Sub Activity_Resume
End Sub
Sub Activity_Pause (UserClosed As Boolean)
End Sub
private Sub button1_click()
Activity.LoadLayout("B4XSwitch")
B4XSwitch1.mBase.Left=10dip
mTop=mTop+40dip
B4XSwitch1.mBase.Top=mTop
B4XSwitch1.Value=True
End Sub