Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How can I hide or minimize windows form?
Message
From
15/12/2006 14:53:23
Keith Payne
Technical Marketing Solutions
Florida, United States
 
 
To
14/12/2006 21:12:13
Dave Porter
Medical Systematics, Inc.
Merced, California, United States
General information
Forum:
ASP.NET
Category:
Coding, syntax and commands
Miscellaneous
Thread ID:
01177859
Message ID:
01178112
Views:
16
>I have a C# windows form that when you click one of the buttons, it starts another process and waits for it to finish. It works fine. BUT when the process finishes, my form is displayed for a second or two or three, it looks funky! The buttons and other controls are not there and there is leftover crud from the finished process displayed in their place and it just doesn't look professional. Is there a way to avoid this problem or can I hide or minimize the form while the process is runnning and restore it when the process finishes? thanks in advance! Dave
>
>using (Process proc = Process.Start(msiprog, msiparams))
> {
> if (msiWait)
> proc.WaitForExit();
> //if(proc.ExitCode == 0) return true;
> }

Dave,

It might be better to use a loop and WaitForExit(250) to allow the window to respond to paint events. It might also help to Invalidate the window immediately after the loop terminates.
Previous
Reply
Map
View

Click here to load this message in the networking platform