|
-
Oct 31st, 2002, 12:20 PM
#1
Thread Starter
New Member
Wait for process
I am looping system.diagnostics.process.start this code works when I put a break in the code and single step it thru waiting for each line to finish. but if I don't use a break or step it thru quickly the process I am trying to start doesn't have a chance to finish the first time around before it loops and is ready to start again. Is there a way to make it wait for a process before moving on to the next?
Dim ProgramsSelected As Int16
Dim count As Int16 = 0
ProgramsSelected = newProgramList.SelectedItems.Count
Do
count += 1
System.Diagnostics.Process.Start _(newProgramList.SelectedItem)
newProgramList.SetSelected _(newProgramList.SelectedIndex, False)
Loop Until count = ProgramsSelected
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
|