Problem with dealing with UI update on progress window

I did that. no improvement. again all other items are refreshing and not the progressbar.
now the canvas is refreshing as the other items, and the cavnasprogressbar looks ok !

Well… I made a test here and it works. At least on Windows.

the progressbar is smaller and top right, the canvas works fine …

Enregistrement de l’écran 2023-03-09 à 15.39.32.2023-03-09 15_41_57

Well… A hammered workaround is not a solution. You are collecting lots of tech debts over time and doing lots of “don’t do it” as DoEvents(). But… the rules I follow are not the rules everyone follows…

completely agree with you, but I already spend half a day on this and it is way too much.
this “hack” will work some time, and I can revisit it later. but not now.

Can you share this sample (progressbar stuck at top)?

other xojo examples of progressbar are working fine on my system.
so I presume it is something with the other parts of the app
will try to make a test project that is failing, but as often the test project is working fine …

1 Like

funny thing, in the last xojo 2022r41, when you build the project, the progressbar does not progress…

What OS are you using? (I’m sorry if I missed it)
Is just the building progressbar or also the one when you open a project?

macos 13 ventura
it is only when I build.
when I open a project the progress is correct
when I run a project it is correct too (although it doesn’t move a lot it still moves)

Ventura 13.2.1? or a beta version?
Intel or Apple?
I don’t have this problem with 13.2.1/Intel

13.2.1 Apple Silicon

and, as expected, a sample project with only the same progressing window class works just fine …
progressbar on top, canvas on bottom …

Enregistrement de l’écran 2023-03-11 à 11.23.24.2023-03-11 11_25_10

could it be that it somehow was disabled?

same class, copy-paste in a new project. so there is something in the big app project that prevents it from updating. but where …

Check and see what the CPU usage looks like in both apps. It could be that you have another main thread CPU hog running concurrently in your big app.

But if it is happening in Xojo too in that machine I don’t think it will matter what changes are done.

Anyone else see the same with Ventura 13.2.1 with Apple Silicon (no move in progress bar while building)?

1 Like

If you watch your original video in this post you will see that the ProgressBar does update once (it goes from zero to about 5%) and then stops. This suggests to me it may be a logic bug on your part, e.g. perhaps you aren’t setting ProgressBar1.value other than once?

I would do something like this:

 UpdateProgressBar(newValue as double)
     ProgressBar1.value = newValue
     system.debugLog "Set ProgressBar1 to " + str(newValue) + " out of " + str(ProgressBar1.maximumValue)

Run it in the debugger and watch the Log pane to be 100% sure it’s being updated.

1 Like

@Mike_D , on this previous post

I displayed the value stored in the progressbar one line above as a label
as you can see, it was correctly updated, but not the progressbar.
and you’re right, the progressbar starts to move a little, but stops after a small time.

sorry folks, but I cleaned up this progress window, used a canvas instead. works fine now
there is still a mystery there, just for the records if anyone in the future is stuck on same behavior ?
thanks to everyone for their help.