i am trying to select 92000 records from the database. obivously, it will be a while
but instead of displaying each bar every second or seomthing, the radprogressbar just wait until everything is finished and then display it in full bar. how can i stop that how can i make it the progress bar fill up slower?
but instead of displaying each bar every second or seomthing, the radprogressbar just wait until everything is finished and then display it in full bar. how can i stop that how can i make it the progress bar fill up slower?
While rs.Read
RadProgressBar2.Value1 = i
RadProgressBar2.Text =
"Record " & i
i = i + 1
End While
please help thank you
4 Answers, 1 is accepted
0

appdev
Top achievements
Rank 1
answered on 05 Feb 2009, 09:03 PM
i put a radprogressbar2.refresh in there an i can see it and made it moves slower but i can't do anything with my form. i can't even move my form???? is the progress bar engine really heavy?
0
Hi Duy,
Thanks for writing.
Could you please give us more details on how you organized your approach?
Basically, when you want to use the RadProgressBar in the context of a lengthy operation you should implement a worker thread pattern. In other words, you should use additional thread to fetch and load the information from the database. This thread will also update the RadProgressBar which will work in the main thread of your application.
Note that the default architecture of a Windows Forms application is organized in such a way, that the main thread manages the UI plus the operations that are executed behind, unless you explicitly create other thread(s) to do this. This is the reason why when you run a lengthy operation the GUI cannot be updated until the operation is finished.
I hope this helps.
Best wishes,
Deyan
the Telerik team
Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Thanks for writing.
Could you please give us more details on how you organized your approach?
Basically, when you want to use the RadProgressBar in the context of a lengthy operation you should implement a worker thread pattern. In other words, you should use additional thread to fetch and load the information from the database. This thread will also update the RadProgressBar which will work in the main thread of your application.
Note that the default architecture of a Windows Forms application is organized in such a way, that the main thread manages the UI plus the operations that are executed behind, unless you explicitly create other thread(s) to do this. This is the reason why when you run a lengthy operation the GUI cannot be updated until the operation is finished.
I hope this helps.
Best wishes,
Deyan
the Telerik team
Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0

David Parvin
Top achievements
Rank 1
answered on 19 Sep 2011, 10:35 PM
The problem is not with your progress bar but with the fact that the tight loop is not letting anything else happen. Try putting a System.Windows.Forms.Application.DoEvents() into your loop and it will allow other things like moving your form to happen.
0

Rishi
Top achievements
Rank 1
answered on 24 Apr 2012, 06:22 PM
This solution worked for me