B4J Question Progressbar in a modalform

lumbanico

Member
Hello!

I am developing an application in B4J.

From a main form I call another in modalform, which contains a progressbar with value -1, so that it should be constantly "scrolling", but it doesn't move.

I call the modalform as follows:

B4X:
Private modalformwait As modProgress
modalformwait.Initialize(MainForm)
modalformwait.Show

And the modalform code is the following:

B4X:
Sub Class_Globals
 
Private fx As JFX
Private xui As XUI
Private frmProgress As Form
Private ProgressBar1 As ProgressBar
 
End Sub

Public Sub Initialize (Parent As Form)
 
frmProgress.Initialize("frmProgress", 400dip, 200dip)
frmProgress.Resizable = False
frmProgress.SetFormStyle("UNDECORATED")
frmProgress.RootPane.LoadLayout("frmProgress")
frmProgress.Title = "Wait..."
    frmProgress.SetOwner(Parent)
 
ProgressBar1.Progress = -1

End Sub

Public Sub Show
 
    frmProgress.Show
 
End Sub

Public Sub Hide

    frmProgress.Close
 
End Sub

Sub frmProgress_CloseRequest (EventData As Event)
 
    EventData.Consume

End Sub

Why the progressbar doesn't work?

Thanks.
 

lumbanico

Member
Hello!

I attach a small example where you can see that the Progressbar does not work.

I'm a newbie, and I don't know how else I can open forms that are in control. What alternatives are there to the modal form?

Thank you so much!
 

Attachments

  • ModalForm.zip
    3.6 KB · Views: 181
Upvote 0

Erel

B4X founder
Staff member
Licensed User
Longtime User
It does move here:

1670836435986.png


?

I'm using OpenJDK 11 or 14.
 
Upvote 0

lumbanico

Member
Doesn´t work. I've tested with OpenJDK 11, 12, 13 and 14.

I think the problem is in the OpenJDK version, because with OpenJDK 8 works. But with OpenJDK 8 not work UCanAccess and JasperReport, than i'm using in the app too. ?
 
Upvote 0
Top