By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
454,632 Members | 1,340 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 454,632 IT Pros & Developers. It's quick & easy.

VBScript launched from GPO in AD fails.

P: 6
Could I please get a little help with this script. I am trying to push from server to workstation to install AdAware client. I am using Group Policy with a logon policy.
Thanks in advance.


//Beginning of the VBscript file For Client Installing

Option Explicit

Dim theShell

Set theShell = WScript.CreateObject("WScript.Shell")

theShell.Run "msiexec.exe /i /a \\SAVG\Client Setup\AAwEntC.msi /quiet /qn /norestart SERVER_PORT=10020 SERVER_HOST=192.168.1.1 CLIENT_PORT=10010"

Set theShell = Nothing

WScript.Quit(0)

//End of the file
Nov 29 '06 #1
Share this Question
Share on Google+
9 Replies


sashi
Expert 100+
P: 1,754
Could I please get a little help with this script. I am trying to push from server to workstation to install AdAware client. I am using Group Policy with a logon policy.
Thanks in advance.


//Beginning of the VBscript file For Client Installing

Option Explicit

Dim theShell

Set theShell = WScript.CreateObject("WScript.Shell")

theShell.Run "msiexec.exe /i /a \\SAVG\Client Setup\AAwEntC.msi /quiet /qn /norestart SERVER_PORT=10020 SERVER_HOST=192.168.1.1 CLIENT_PORT=10010"

Set theShell = Nothing

WScript.Quit(0)

//End of the file
Hi there,

What is the output? Any error message / error code/number being prompt? Take care.
Nov 29 '06 #2

P: 6
Hi there,

What is the output? Any error message / error code/number being prompt? Take care.
Thanks for quick reply.
It gives me :
Line:1
Char:1
Error: Expected statement
Code: 80A0400
Source Microsoft VBScript compilation error
Nov 29 '06 #3

sashi
Expert 100+
P: 1,754
Thanks for quick reply.
It gives me :
Line:1
Char:1
Error: Expected statement
Code: 80A0400
Source Microsoft VBScript compilation error
Hi there,

I think i know the reason, it's the comment line i guess, hope this works. Kindly refer to below modification, make changes as below. Take care.

Expand|Select|Wrap|Line Numbers
  1.  // - in your current comment line
  2.  change it ot
  3.  '// - your new comment line
  4.  
it should look below..

Expand|Select|Wrap|Line Numbers
  1. '//Beginning of the VBscript file For Client Installing 
  2.  
  3. Option Explicit 
  4.  
  5. Dim theShell 
  6.  
  7. Set theShell = WScript.CreateObject("WScript.Shell") 
  8.  
  9. theShell.Run "msiexec.exe /i /a \\SAVG\Client Setup\AAwEntC.msi /quiet /qn /norestart SERVER_PORT=10020 SERVER_HOST=192.168.1.1 CLIENT_PORT=10010" 
  10.  
  11. Set theShell = Nothing 
  12.  
  13. WScript.Quit(0) 
  14.  
  15. '//End of the file
  16.  
Nov 29 '06 #4

P: 6
Hi there,

What is the output? Any error message / error code/number being prompt? Take care.
I am using a program called web-ed to check the script and found the first and last lines begining with // needed to removed. Then I run the script and the Windows Installer is launched giving me all the options listed below.
Windows Installer. V 3.01.4000.1823

msiexec /Option <Required Parameter> [Optional Parameter]

Install Options
</package | /i> <Product.msi>
Installs or configures a product
/a <Product.msi>
Administrative install - Installs a product on the network
/j<u|m> <Product.msi> [/t <Transform List>] [/g <Language ID>]
Advertises a product - m to all users, u to current user
</uninstall | /x> <Product.msi | ProductCode>
Uninstalls the product
Display Options
/quiet
Quiet mode, no user interaction
/passive
Unattended mode - progress bar only
/q[n|b|r|f]
Sets user interface level
n - No UI
b - Basic UI
r - Reduced UI
f - Full UI (default)
/help
Help information
Restart Options
/norestart
Do not restart after the installation is complete
/promptrestart
Prompts the user for restart if necessary
/forcerestart
Always restart the computer after installation
Logging Options
/l[i|w|e|a|r|u|c|m|o|p|v|x|+|!|*] <LogFile>
i - Status messages
w - Nonfatal warnings
e - All error messages
a - Start up of actions
r - Action-specific records
u - User requests
c - Initial UI parameters
m - Out-of-memory or fatal exit information
o - Out-of-disk-space messages
p - Terminal properties
v - Verbose output
x - Extra debugging information
+ - Append to existing log file
! - Flush each line to the log
* - Log all information, except for v and x options
/log <LogFile>
Equivalent of /l* <LogFile>
Update Options
/update <Update1.msp>[;Update2.msp]
Applies update(s)
/uninstall <PatchCodeGuid>[;Update2.msp] /package <Product.msi | ProductCode>
Remove update(s) for a product
Repair Options
/f[p|e|c|m|s|o|d|a|u|v] <Product.msi | ProductCode>
Repairs a product
p - only if file is missing
o - if file is missing or an older version is installed (default)
e - if file is missing or an equal or older version is installed
d - if file is missing or a different version is installed
c - if file is missing or checksum does not match the calculated value
a - forces all files to be reinstalled
u - all required user-specific registry entries (default)
m - all required computer-specific registry entries (default)
s - all existing shortcuts (default)
v - runs from source and recaches local package
Setting Public Properties
[PROPERTY=PropertyValue]

Consult the Windows Installer SDK for additional documentation on the
command line syntax.

Copyright Microsoft Corporation. All rights reserved.
Portions of this software are based in part on the work of the Independent JPEG Group.
Nov 29 '06 #5

sashi
Expert 100+
P: 1,754
I am using a program called web-ed to check the script and found the first and last lines begining with // needed to removed. Then I run the script and the Windows Installer is launched giving me all the options listed below.
Windows Installer. V 3.01.4000.1823

msiexec /Option <Required Parameter> [Optional Parameter]

Install Options
</package | /i> <Product.msi>
Installs or configures a product
/a <Product.msi>
Administrative install - Installs a product on the network
/j<u|m> <Product.msi> [/t <Transform List>] [/g <Language ID>]
Advertises a product - m to all users, u to current user
</uninstall | /x> <Product.msi | ProductCode>
Uninstalls the product
Display Options
/quiet
Quiet mode, no user interaction
/passive
Unattended mode - progress bar only
/q[n|b|r|f]
Sets user interface level
n - No UI
b - Basic UI
r - Reduced UI
f - Full UI (default)
/help
Help information
Restart Options
/norestart
Do not restart after the installation is complete
/promptrestart
Prompts the user for restart if necessary
/forcerestart
Always restart the computer after installation
Logging Options
/l[i|w|e|a|r|u|c|m|o|p|v|x|+|!|*] <LogFile>
i - Status messages
w - Nonfatal warnings
e - All error messages
a - Start up of actions
r - Action-specific records
u - User requests
c - Initial UI parameters
m - Out-of-memory or fatal exit information
o - Out-of-disk-space messages
p - Terminal properties
v - Verbose output
x - Extra debugging information
+ - Append to existing log file
! - Flush each line to the log
* - Log all information, except for v and x options
/log <LogFile>
Equivalent of /l* <LogFile>
Update Options
/update <Update1.msp>[;Update2.msp]
Applies update(s)
/uninstall <PatchCodeGuid>[;Update2.msp] /package <Product.msi | ProductCode>
Remove update(s) for a product
Repair Options
/f[p|e|c|m|s|o|d|a|u|v] <Product.msi | ProductCode>
Repairs a product
p - only if file is missing
o - if file is missing or an older version is installed (default)
e - if file is missing or an equal or older version is installed
d - if file is missing or a different version is installed
c - if file is missing or checksum does not match the calculated value
a - forces all files to be reinstalled
u - all required user-specific registry entries (default)
m - all required computer-specific registry entries (default)
s - all existing shortcuts (default)
v - runs from source and recaches local package
Setting Public Properties
[PROPERTY=PropertyValue]

Consult the Windows Installer SDK for additional documentation on the
command line syntax.

Copyright Microsoft Corporation. All rights reserved.
Portions of this software are based in part on the work of the Independent JPEG Group.
Hi there,

This is because vb / vbscript doesn't take (//) as comment, instead it takes (') as comment. Try changing the line and lets see what turns up next. Good luck & Take care.
Nov 29 '06 #6

P: 6
Hi there,

This is because vb / vbscript doesn't take (//) as comment, instead it takes (') as comment. Try changing the line and lets see what turns up next. Good luck & Take care.

It still launches the Windows Installer window.
Nov 29 '06 #7

sashi
Expert 100+
P: 1,754
It still launches the Windows Installer window.
Hi there,

Isn't that a good news :), now you probably need pass proper parameters along. Good luck & Take care.
Nov 29 '06 #8

P: 6
Hi there,

Isn't that a good news :), now you probably need pass proper parameters along. Good luck & Take care.

What required parameters are you refering? after the msiexec.exe...
The path after is to my savg server to a share "client setup to hit executable.

theShell.Run "msiexec.exe /i /a \\SAVG\Client Setup\AAwEntC.msi /i /quiet /qn /norestart SERVER_PORT=10020 SERVER_HOST=192.168.1.1 CLIENT_PORT=10010"
Nov 29 '06 #9

P: 6
What required parameters are you refering? after the msiexec.exe...
The path after is to my savg server to a share "client setup to hit executable.

theShell.Run "msiexec.exe /i /a \\SAVG\Client Setup\AAwEntC.msi /i /quiet /qn /norestart SERVER_PORT=10020 SERVER_HOST=192.168.1.1 CLIENT_PORT=10010"
Is this more traditional:
'Run' theShell.Run = "msiexec.exe '\\SAVG\Client Setup\AAwEntC.msi /i /quiet /qn /norestart SERVER_PORT=10020 SERVER_HOST=192.168.1.1 CLIENT_PORT=10010"
Nov 29 '06 #10

Post your reply

Sign in to post your reply or Sign up for a free account.