Doubts on vbscript file running in AI - Advanced Installer Community

We’re moving our forums to a new platform.

You can still browse and search existing topics, but you can no longer create new topics or post replies.

For questions, technical issues, or feature requests, please don’t hesitate to contact our support team at support@advancedinstaller.com.

Thank you for your understanding!

udayk
Posts: 126
Joined: Thu Jan 19, 2012 12:30 pm

Doubts on vbscript file running in AI

Hi Team,

I processed a vbscript file in Standard action "Commit"
'Set JAVA_HOME, JRE_HOME and update PATH
set shellObj = WScript.CreateObject("WScript.Shell")
set envObj = shellObj.Environment("User")
envObj("JAVA_HOME")="C:\Program Files\Java\jdk1.5.0_16"
envObj("Path")="C:\Program Files\Java\jdk1.5.0_16\bin"


In my Script dont have any function.

the above script run in manually it works fine but, if it run through AI it shows in error.

Can any one please resolve my expception.

Thank you,
Udayk.
Attachments
Throwing error
Throwing error
Problem-on-Installation.png (70.61 KiB) Viewed 6906 times
vbscript assigning
vbscript assigning
vbscript-error.png (197.39 KiB) Viewed 6906 times
udayk
Posts: 126
Joined: Thu Jan 19, 2012 12:30 pm

Re: Doubts on vbscript file running in AI

Error is

script error -2146827864, Microsoft VBScript runtime error: Object required: 'WScript'

Thank you,
Udayk.
mihai.petcu
Posts: 3860
Joined: Thu Aug 05, 2010 8:01 am

Re: Doubts on vbscript file running in AI

Hi Udayk,

Here's the "Why does my VBScript custom action fail to run?" FAQ to help you with this:
http://www.advancedinstaller.com/user-g ... question47

All the best,
Mihai
Mihai Petcu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
udayk
Posts: 126
Joined: Thu Jan 19, 2012 12:30 pm

Re: Doubts on vbscript file running in AI

Thank you Mihai,

I solved this issue, it is working fine.

Thank you,
Udayk.

Return to “Common Problems”