Public Sub MinimizeForm(Frm As Form)
Dim jForm As JavaObject = Frm
Dim stage As JavaObject = jForm.GetField("stage")
stage.RunMethod("setIconified", Array As Object(True))
End Sub
Esempio:
Private Sub Button1_Click
MinimizeForm(B4XPages.GetNativeParent(Me).As(Form))
End Sub
Public Sub MaximizeForm(Frm As Form)
Dim jForm As JavaObject = Frm
Dim stage As JavaObject = jForm.GetField("stage")
stage.RunMethod("setFullScreen", Array As Object(True))
End Sub
e poi:
B4X:
Private Sub Button1_Click
MaximizeForm(B4XPages.GetNativeParent(Me).As(Form))
End Sub
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.