|
-
Mar 6th, 2006, 05:36 PM
#1
Thread Starter
Junior Member
[RESOLVED] Launch external app and wait
Hi,
I can shell execute a programme, but I want to wait until that program is finished running before continuing on to the next line of code, is this possible?
Thanks in advance.
-
Mar 6th, 2006, 05:42 PM
#2
Re: Launch external app and wait
do a search for ShellAndWait.
For example, see #17 in this post
-
Mar 6th, 2006, 05:43 PM
#3
Thread Starter
Junior Member
Re: Launch external app and wait
Thanks for the quick reply!
-
Mar 6th, 2006, 06:24 PM
#4
Thread Starter
Junior Member
Re: Launch external app and wait
Hmm, I get an "invalid procedure call or argument" error at the
VB Code:
executionStatus = Shell(FileName, vbNormalFocus)
Line....
Am I missing something?
Forgive me it has been a long day...
Thanks
-
Mar 6th, 2006, 06:30 PM
#5
Re: Launch external app and wait
what is the value of 'filename' that you're passing to the procedure?
-
Mar 6th, 2006, 07:13 PM
#6
Thread Starter
Junior Member
Re: Launch external app and wait
Actually, I think that may be part of the problem...
VB Code:
fileName = AppPath & "\files\MSDE\SqlRun16.msi disablenetworkprotocols=0 blanksapwd=1 securitymode=sql instancename=_T7DEMO_DB"
I think it's the command line parameters that are messing it up... I thought I might be able to get away with including them as part of the string...
any suggestions?
Main reason Im doing this is as a front end for my installer, since i seem to be failing miserably with InstallShield 11 and getting it to install the MSDE first before prompting for SQL login....
Thanks alot for the help...
-
Mar 6th, 2006, 07:28 PM
#7
Re: Launch external app and wait
I just did a little test and I had no problems passing cmd line parameters.
Just to check, is AppPath a typo? It should be App.Path
Have you tried getting it to work without passing the parameters?
-
Mar 6th, 2006, 07:34 PM
#8
Thread Starter
Junior Member
Re: Launch external app and wait
Yeah, a typo ( I manually typed the code here) but now that you mention it.........
Ill have to look into the code again. Im at home now, I'll VPN into my computer at work and take a look. No doubt I typo'd it in the code as well....
What a long day it has been!
Thanks!
-
Mar 6th, 2006, 08:01 PM
#9
Thread Starter
Junior Member
-
Mar 6th, 2006, 08:08 PM
#10
Re: Launch external app and wait
 Originally Posted by jtruxxer
Happens to the best of us
maybe I should enlist you to proof read my code for typo's!!!!!!!
got enough of them in my own code thanks!
-
Mar 6th, 2006, 08:09 PM
#11
Frenzied Member
Re: Launch external app and wait
This thread has been resolved if i'm not mistaken, so lets help the mods by marking this as Resolved. see instruction in my signature
On error goto Trap
Trap:
in case of emergency, drop the case...
****************************************
If this post has been resolved. Please mark it as "Resolved" by going through the "Thread Tools" above and clicking on the "Mark Thread Resolved " option. if a post is helpful to you, Please Rate it by clicking on the Rate link right below the avatar
-
Mar 6th, 2006, 08:14 PM
#12
Thread Starter
Junior Member
Re: [RESOLVED] Launch external app and wait
Done! Thanks for the reminder
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
|