Click here to Skip to main content
15,891,423 members
Home / Discussions / C#
   

C#

 
GeneralRe: Problem with HasExited and WaitForExit() [modified] Pin
DaveyM698-Feb-08 11:38
professionalDaveyM698-Feb-08 11:38 
GeneralRe: Problem with HasExited and WaitForExit() Pin
Luc Pattyn8-Feb-08 11:46
sitebuilderLuc Pattyn8-Feb-08 11:46 
GeneralRe: Problem with HasExited and WaitForExit() Pin
DaveyM698-Feb-08 11:54
professionalDaveyM698-Feb-08 11:54 
GeneralRe: Problem with HasExited and WaitForExit() Pin
Guffa8-Feb-08 12:41
Guffa8-Feb-08 12:41 
GeneralRe: Problem with HasExited and WaitForExit() Pin
engsrini8-Feb-08 13:20
engsrini8-Feb-08 13:20 
GeneralRe: Problem with HasExited and WaitForExit() Pin
mav.northwind8-Feb-08 20:07
mav.northwind8-Feb-08 20:07 
GeneralRe: Problem with HasExited and WaitForExit() Pin
PIEBALDconsult9-Feb-08 4:36
mvePIEBALDconsult9-Feb-08 4:36 
GeneralRe: Problem with HasExited and WaitForExit() Pin
danielhasdibs11-Feb-08 3:43
danielhasdibs11-Feb-08 3:43 
Ok, I don't want to be one of those jerks who finds the answer and doesn't share so I have the working code here. I don't know why this didn't work before, but it didn't, and now it does, so I'm happy.

System.Diagnostics.ProcessStartInfo psi = new System.Diagnostics.ProcessStartInfo();<br />
                                        psi.RedirectStandardOutput = true;<br />
                                        psi.WindowStyle = System.Diagnostics.ProcessWindowStyle.Maximized;<br />
                                        psi.UseShellExecute = false;<br />
                                        psi.Arguments = txt_Wordfile.Text + " /n";<br />
                                        psi.FileName = WordExe; //string<br />
<br />
                                        System.Diagnostics.Process WordProcess = new System.Diagnostics.Process();<br />
<br />
                                        WordProcess = System.Diagnostics.Process.Start(psi);<br />
<br />
                                        WordProcess.EnableRaisingEvents = true;<br />
                                        while (!WordProcess.HasExited)<br />
                                        {<br />
                                            ;<br />
                                        }<br />
                                        WordProcess.Kill();                                       <br />
<br />
<br />
                                        System.Diagnostics.Process.Start(txt_website.Text);


Thanks everyone for your help!
GeneralRe: Problem with HasExited and WaitForExit() Pin
Martin#11-Feb-08 23:50
Martin#11-Feb-08 23:50 
GeneralWindows Mobile GPS Application Issue Pin
Simerjots8-Feb-08 6:55
Simerjots8-Feb-08 6:55 
GeneralRe: Windows Mobile GPS Application Issue Pin
Gareth H8-Feb-08 9:00
Gareth H8-Feb-08 9:00 
GeneralRe: Windows Mobile GPS Application Issue Pin
Simerjots8-Feb-08 9:15
Simerjots8-Feb-08 9:15 
GeneralRe: Windows Mobile GPS Application Issue Pin
Simerjots8-Feb-08 14:20
Simerjots8-Feb-08 14:20 
General[Message Deleted] Pin
bruze8-Feb-08 5:42
bruze8-Feb-08 5:42 
GeneralRe: How to voice xml wave file srored in folder using c# aspx. Pin
Bert delaVega8-Feb-08 5:59
Bert delaVega8-Feb-08 5:59 
GeneralRe: [Message Deleted] Pin
engsrini8-Feb-08 13:38
engsrini8-Feb-08 13:38 
QuestionMobile app, auto-upgrade through web service Pin
JGentsch8-Feb-08 4:03
JGentsch8-Feb-08 4:03 
AnswerRe: Mobile app, auto-upgrade through web service Pin
JGentsch8-Feb-08 4:42
JGentsch8-Feb-08 4:42 
GeneralRe: Mobile app, auto-upgrade through web service Pin
led mike8-Feb-08 4:45
led mike8-Feb-08 4:45 
GeneralChanging Form Colors from XML Pin
s3rro8-Feb-08 3:57
s3rro8-Feb-08 3:57 
GeneralRe: Changing Form Colors from XML Pin
led mike8-Feb-08 4:35
led mike8-Feb-08 4:35 
GeneralRe: Changing Form Colors from XML Pin
s3rro8-Feb-08 4:45
s3rro8-Feb-08 4:45 
GeneralRe: Changing Form Colors from XML Pin
led mike8-Feb-08 6:51
led mike8-Feb-08 6:51 
GeneralRe: Changing Form Colors from XML Pin
Gareth H8-Feb-08 9:03
Gareth H8-Feb-08 9:03 
GeneralRe: Changing Form Colors from XML Pin
Bert delaVega8-Feb-08 7:24
Bert delaVega8-Feb-08 7:24 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.