I have used this code before to do something similar before... If you go to: http://www.mvps.org/vb/ and look in the Samples area for 'Shell32.zip', it has a library with several methods to call and wait for applications to shell, etc. Hope that helps. -Craig Tucker -----Original Message----- From: pic microcontroller discussion list [mailto:PICLIST@MITVMA.MIT.EDU]On Behalf Of Sean Breheny Sent: Friday, April 06, 2001 1:47 PM To: PICLIST@MITVMA.MIT.EDU Subject: [OT]: Shelling in VB Hi everyone, Once again, I have a Visual Basic question and you are the most knowledgeable group I know on this subject. I'm trying to run an external program from a VB program (the external program is actually XXCOPY, as mentioned on this list not long ago, because I am using it for backing stuff up over a network). It is working well except that I can't find a way to make it wait for the first process to finish before spawning a new one (so, if I want to sequentially call XXCOPY 10 times, I instead get 10 copies running simultaneously). I could probaby do some kind of trick where I have XXCOP log it's output to a file and then keep checking the file for the last line to be written, but I thought that possibly VB would have a built-in way of doing this (I'm currently using the SHELL command and that appears to not have any option like this). Thanks, Sean -- http://www.piclist.com hint: To leave the PICList mailto:piclist-unsubscribe-request@mitvma.mit.edu 7 -- http://www.piclist.com hint: To leave the PICList mailto:piclist-unsubscribe-request@mitvma.mit.edu