Intermittent VB Script Error Creating IE Object

I use a VB script several times daily to automate part of a remote login procedure.

Most times it works.  For reasons I don't understand, there are times it doesn't and throws the error below:

The error points to this line in the script:

Set IE = WScript.CreateObject("InternetExplorer.Application", "IE_")

RemoteLogin-IE-Error

If I then manually open IE, and re-run the script it will work.  If I then close out the remote terminal session, close out IE and re-run the script exactly the same way I did when it threw the above error, it runs fine.

I don't understand the cause of this intermittent error.

Thx
qengAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

QlemoBatchelor, Developer and EE Topic AdvisorCommented:
The script will always open a new IE, so the issue is most likely related to some timeout because starting IE lasts too long temporarily. I have to guess, because the screenshot (?) you provided does not have an extension, and no format I know of (please repost if important).
0
qengAuthor Commented:
Hi Qlemo,  thanks for your input.

I've used this script several times a day for months now so it certainly  does open IE as you say, but it doesn't do it every time.

For reasons unknown, sometimes it doesn't.  And if i try to re-run it, without taking the steps noted above, it will keep generating the attached error (i'm not sure if the image I uploaded earlier was correct, I'm re-uploading).

thx
Screen-Shot-2015-06-17-at-3.42.45-AM.png
0
QlemoBatchelor, Developer and EE Topic AdvisorCommented:
Interesting. I assume you start the VBS completely anew each time (versus running it in another script)?
If that would happen to me I'll run Process Monitor from SysInternals (now MIcrosoft) with Registry and File access monitoring while the error pops up. But that will result in a lot of entries to analyze. I usually exclude processes, files etc. stepwise by using the context menu on each uninteresting entry, to drill down to the potentially interesting stuff. Still tedious, though.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
VB Script

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.