cycledude
asked on
c# winforms class to display 'please wait'
Hi
I am trying to create a class that displays a message in a panel which is centered on the screen... a simple 'please wait' would be fine, so that I can call something like
busy()
to display the message no matter what form is open in the application...
Any ideas how I get this to work?
Cheers
CD
I am trying to create a class that displays a message in a panel which is centered on the screen... a simple 'please wait' would be fine, so that I can call something like
busy()
to display the message no matter what form is open in the application...
Any ideas how I get this to work?
Cheers
CD
ASKER
ah i see, so create a form with the message in it and then display the form...
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
so simple
I was thinking of creating a class, which created a panel in code then added a label and an image, then set the message... but this is way easier.. thanks
I was thinking of creating a class, which created a panel in code then added a label and an image, then set the message... but this is way easier.. thanks
ASKER
;o)
The trick is the .Show() so it doesn't block the code. However it does require you to close the form from code yourself.
eg.
MyWaitForm frm = new MyWaitForm();
frm.Show();
.... //your code goes here
frm.Close();