How to change cursor while loading data from the database and set it to default after

Joined
Jun 7, 2012
Messages
5
Programming Experience
Beginner
Hi, I just want my UI become user friendly with changing mouse cursor while loading data from the database,
because while it is loading a plenty of data it paused.

"How to change cursor while loading data from the database and set it to default after"

How can I do that ?
 
Set the UseWaitCursor property of the form to True and then do the actual work on a secondary thread. Once the work is complete, set the property back to False. The simplest option for that is to use a BackgroundWorker. Do the work in the DoWork event handler and reset the property in the RunWorkerCompleted event handler. Just make absolutely sure that you reset the property even if an exception is thrown.
 
Back
Top