|
-
February 21st, 2006, 12:22 PM
#1
process problem
Hi everybody,
Here's my problem :
I want to be able to show or hide a process window while it is running.
Here is my code :
Process p = null;
p = new Process();
p.StartInfo.WorkingDirectory = "c:\\Program Files\\Internet Explorer\\";
p.StartInfo.FileName = "iexplore.exe";
p.StartInfo.CreateNoWindow = true;
p.StartInfo.WindowStyle = ProcessWindowStyle.Hidden;
p.Start();
while (!p.HasExited)
{
Application.DoEvents();
if (showProcess)
{
// Which code here ??
}
Thread.Sleep(100);
}
void button_showOrHideProcess_click (...)
{
showProcess = !showProcess;
}
obviously process.startInfo has no effect when process is already running, so how can I make window visible ?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|