Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I'm trying to use VBScript to launch a web form that requires the user to fill it out and then at the end of it, check whether they completed the form or cancelled out. I do not have control over the form itself (encoded javascript mess), but I can tell whether the form was completed by virtue of the results saved in Active Directory (user attribute is modified). I'd like to be able to run my script, check for the attribute, if not configured properly it launches the web form in IE, and waits until the IE session is closed, then checks the same LDAP attribute to determine what the user did. If they didn't complete the form properly, I need it to log them off. I can make everything work except pausing the script while IE is active. I've tried...

retval = objShell.Run("iexplore.exe " & url, 1, True) wscript.echo "browser session finished"

But the RUN method ignores "iexplore.exe" and continues on (even with Wait=True). All of the script examples for launching via CreateObject("InternetExplorer.Application") use the Sleep method, but I can't use a fixed timer duration. Some users take much longer than others. I hope this makes sense. I just need to be able to launch IE and wait for it to be closed.

share|improve this question

1 Answer 1

Here's the answer: http://skatterbrainz.blogspot.com/2011/02/launch-ie-and-wait-for-it-to-be-closed.html

share|improve this answer
1  
It's good that you found the solution, but just a link is considered spam when it's right to your own blog. Care to share the solution here? –  random Apr 25 '11 at 2:43

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.