Problem with Wait Cursor

G

Guest

Hi,
I am using the below code for displaying the Wait cursor.

Cursor.Current = Cursors.WaitCursor;

But currently in some cases the wait cursor is not getting displayed at all
and in some cases there is more than 5 Seconds delay before the wait cursor
is displayed.

Can some one tell me why this is happening??

How can i avoid this problem??

Thanks in Advance,
Murthy
 
P

paul.edmondson

Hi,
I am using the below code for displaying the Wait cursor.

Cursor.Current = Cursors.WaitCursor;

But currently in some cases the wait cursor is not getting displayed at all
and in some cases there is more than 5 Seconds delay before the wait cursor
is displayed.

Can some one tell me why this is happening??

How can i avoid this problem??

Thanks in Advance,
Murthy


You may find that there is probably a dealy in loading objects, forms
before the cursor shows.

i.e you may need to set cursor state before instantiating objects or
loading forms. As they are things that can take time.

I have also had this issue and still do in some places. Sometimes
using application.doevents can help


Paul.
 
J

Jerod Houghtelling

I don't know if it will help or not, but you might try to do an
Application.DoEvents() call after setting the cursor.

Cursor.Current = Cursors.WaitCursor;
Application.DoEvents();
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top