• Announcements

    • xper

      MSFN Sponsorship and AdBlockers!   07/10/2016

      Dear members, MSFN is made available via subscriptions, donations and advertising revenue. The use of ad-blocking software hurts the site. Please disable ad-blocking software or set an exception for MSFN. Alternatively, become a site sponsor and ads will be disabled automatically and by subscribing you get other sponsor benefits.
b0r3d

VBS Scripts

74 posts in this topic

Install switches just dont do what you want them to? Well, this thread will hopefully provide answers to thoes programs that dont have the silent install switches you're looking for.

Please contribute any VBS scripts you've found that work :)

Quite a few can be found here

0

Share this post


Link to post
Share on other sites

here's a script for NOD32 Antivirus, change the sleep value according to your machine speed

(you know the deal paste in notepad and save with the vbs extension)

set WshShell = WScript.CreateObject("WScript.Shell")

Wscript.Sleep 9000

WshShell.SendKeys "{DOWN}"

Wscript.Sleep 100

WshShell.SendKeys "{DOWN}"

Wscript.Sleep 100

WshShell.SendKeys "{ENTER}"

Wscript.Sleep 2000


WshShell.SendKeys "{LEFT}"

Wscript.Sleep 100

WshShell.SendKeys "{ENTER}"

Wscript.Sleep 1000


WshShell.SendKeys "{ENTER}"

Wscript.Sleep 1000


WshShell.SendKeys " "

Wscript.Sleep 100

WshShell.SendKeys "{ENTER}"

Wscript.Sleep 1000


WshShell.SendKeys "{DOWN}"

Wscript.Sleep 100

WshShell.SendKeys " "

Wscript.Sleep 100

WshShell.SendKeys "{ENTER}"

Wscript.Sleep 1000


WshShell.SendKeys "{ENTER}"

Wscript.Sleep 1000


WshShell.SendKeys "{UP}"

Wscript.Sleep 100

WshShell.SendKeys "{TAB}"

Wscript.Sleep 100

WshShell.SendKeys "{TAB}"

Wscript.Sleep 100

WshShell.SendKeys "{TAB}"

Wscript.Sleep 100

WshShell.SendKeys " "

Wscript.Sleep 100

WshShell.SendKeys "{ENTER}"

Wscript.Sleep 1000


WshShell.SendKeys " "

Wscript.Sleep 100

WshShell.SendKeys "{ENTER}"

Wscript.Sleep 1000


WshShell.SendKeys "{ENTER}"

Wscript.Sleep 1000


WshShell.SendKeys "{TAB}"

Wscript.Sleep 100

WshShell.SendKeys "{TAB}"

Wscript.Sleep 100

WshShell.SendKeys "{TAB}"

Wscript.Sleep 100

WshShell.SendKeys "{TAB}"

Wscript.Sleep 100

WshShell.SendKeys "{ENTER}"

Wscript.Sleep 1000


WshShell.SendKeys "{ENTER}"

Wscript.Sleep 9000

WshShell.SendKeys "{RIGHT}"

Wscript.Sleep 100

WshShell.SendKeys "{ENTER}"

Wscript.Sleep 2000

WScript.Quit

here's a script for regcleaner (again change the sleep values accordind to your machine speed).

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

WScript.Sleep 1500

WshShell.SendKeys "{Tab}"

WshShell.SendKeys "{Tab}"

WshShell.SendKeys "{Tab}"

WshShell.SendKeys "{Tab}"

WshShell.SendKeys "{ENTER}"

WshShell.SendKeys "{ENTER}"

WScript.Sleep 1000

WScript.Quit

here's a script for winrar 3.2 (context menu without icons and will include only extraxt to,extract here,extract(filename) all file associations are being chosed)

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

WScript.Sleep 3500

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 500

WshShell.SendKeys " "

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys " "

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys " "

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys " "

WScript.Sleep 500

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys " "

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys " "

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys " "

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys " "

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys " "

WScript.Sleep 500

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys " "

WScript.Sleep 100

WshShell.SendKeys "{TAB}"

WScript.Sleep 100

WshShell.SendKeys "{ENTER}"

WScript.Sleep 600

WshShell.SendKeys "{ENTER}"

WScript.Sleep 3500

WshShell.SendKeys "%{F4}"

WScript.Quit

0

Share this post


Link to post
Share on other sites

Hi all,

Im reading a lot of post here, realy nice, thanks m8s.

If you don't already know the Script.Shell has a property/method calld AppActive

With its method you can bring a particularly window to focus.

Using it as a propery you can check if there is a window with that name if so it will get focus.

this will speed up vb script installation helper and you dont have to fine tune the sleep between you actions, you can use a function similar to this

Option Explicit

'to wait for the window "Setup Finish" to appare and press Alt n

'!NOTE! if there are more then one window with the same name it will not work, it will need more work!


dim WshShell, iLoopTimeWait
Set WshShell = WScript.CreateObject("WScript.Shell")
iLoopTimeWait = 500
Call Main()
Set WshShell = Nothing

Sub Main()
  Connect2Window iLoopTimeWait, "Setup Finish"
  WshShell.SendKeys "%n"
End Sub


Function  Connect2Window(iTime, sWindowName)
  Do until WshShell.AppActivate (sWindowName)
     WScript.Sleep iTime
  loop
End function

cheers

::beep

0

Share this post


Link to post
Share on other sites

if people are going to use scripts to automate sendkeys then there is no need for reg tweaks and all the settings that ppl just cant do with the registry simply run file and settings wizard and save all your settings and stuff and then use a vbscript to replace all your settings, that way no need to fiddle with the registry :)

0

Share this post


Link to post
Share on other sites

Sendkeys is so you can automate a program that doesnt have a silent switch, or presents a screen that requires the user to interact on installation. Take winamp for example. At the end of the winamp installation, you're presented with a screen that the user has to press OK on. If a user has to do anything than this defeats the purpose of an unattended installation.

With these vbscripts, they use the sendkeys command to make the software think that someone pressed the OK button. So problem solved. Tricky software that requires user intervention, now doesnt.

0

Share this post


Link to post
Share on other sites

i have managed to save the settings from one machine to another using file and setting transfer wizard and a vbscript

vbs is easier than taking a p**s after 10 pints of lager...lol...

0

Share this post


Link to post
Share on other sites

@devil

Now that is a handy way of doing things.

Care to share that vbs script?

0

Share this post


Link to post
Share on other sites

Here is a example of an installation script fully in vb:

-Edit sysoc.inf

-Copy, move, delete, create files & folders

-Close programs

-Shutdown WinXP without an external program

-Wait for a window to appear, but not endless

On Error Resume Next

'Declare var's and objects
Dim WshS, fso, wi, sysr, sysd, home, aup, cpf, pf, up, upr, app, tool, Stpr, sys32, dllc, f1, t0, t1 ,t2, t5, t7, t10, t15, t30, Btn, i, wmi, os, objset
Set WshS = WScript.CreateObject("WScript.Shell")
Set fso = CreateObject("Scripting.FileSystemObject")

'Expand Environment
'Create const's to spare time and place
sysr = WshS.ExpandEnvironmentStrings("%SystemRoot%")
sysd = WshS.ExpandEnvironmentStrings("%Systemdrive%")
home = WshS.ExpandEnvironmentStrings("%Homepath%")
aup = WshS.ExpandEnvironmentStrings("%AllUsersProfile%")
cpf = WshS.ExpandEnvironmentStrings("%CommonProgramfiles%")
pf = WshS.ExpandEnvironmentStrings("%Programfiles%")
up = WshS.ExpandEnvironmentStrings("%UserProfile%")

'WARNING: I use a "\" at the end.
'The above const's DON'T have a "\" at the end !
app = sysd & "\APPLICATIONS\"
sys32 = sysr & "\System32\"
dllc = sys32 & "\dllcache\"
Stpr = aup & "\Startmenu\Programs\"

'Upr-->%UserProfile%\Startmenu\Programs\
Upr = up & "\Startmenu\Programs\"

'Create a log-file
Set f1 = fso.CreateTextFile(sysd & "\install.log", True)

'Write a line to the log
f1.WriteLine "Begin Installation"

'I don't explain it;-)
f1.WriteBlankLines(1)

'Create const's for use in the script
wi = " is installed"

'Time const's for sleep
t0 = 500
t1 = 1000
t2 = 2000
t5 = 5000
t7 = 7000
t10 = 10000
t15 = 15000
t30 = 30000

'Make some optional components visible for (de)installation
WshS.Run "notepad.exe %systemroot%\inf\sysoc.inf"
WinDo = "sysoc.inf - Editor"
Call SendK("%{e}")

'I think in english is r-->replace
WshS.SendKeys "r"

Wscript.Sleep t1
WshS.SendKeys ",hide,"
WshS.SendKeys "{TAB}"
WshS.SendKeys ",,"
WshS.SendKeys "{TAB 4}"
WshS.SendKeys "~"
WshS.SendKeys "{TAB}"
WshS.SendKeys "~"
Wscript.Sleep t1
WshS.SendKeys "%{F4}"
WinDo = "Editor"
Call SendK("~")

'Show me a box for 2 sec.
WshS.Popup "Create TEMP-Folder",2

'Create Temp-folder
'I set all Temp-folders in the registry to %systemdrive%/Temp,
'cause i hate three or more temp-folders in the 2nd subdir
fso.CreateFolder(sysd & "\Temp")
f1.WriteLine "TEMP-Folder" & wi

'Packets to extract
WshS.Run app & "DirectX9b.exe", 0, true
'true --> same as /wait in batch
'0 --> hide window

'Delete what you (don't) want
fso.DeleteFile(dllc & "scrnsave.scr"), true
'true means--> DO IT!

'Move and copy what you want
fso.MoveFile dllc & "uxtheme.dll", dllc & "uxtheme.old"
fso.MoveFile sys32 & "uxtheme.dll", sys32 & "uxtheme.old"
fso.CopyFile app & "uxtheme.dll", dllc
fso.CopyFile app & "uxtheme.dll", sys32

'Install what you want

WshS.Run "REGEDIT /S " app & "reg.reg", 0, false
fso.CopyFile app & "directx.cpl", sys32 & "\"
f1.WriteBlankLines(1)
f1.WriteLine "Programs and files registered and copied "

WshS.Popup "Install programs",2, StrT,64

'For example
WshS.Run app & "Java141\setup.exe -s -f1" & Chr(34) & app & "Java141\setup.iss" & Chr(34), 0, true
f1.WriteLine "SUN-Java" & wi

WshS.Run app & "MsnMsgs.msi /QB", 0, true
WshS.Run app & "MsgPlus.exe /SilentInstallNoSponsor", 0, true
f1.WriteLine "Messenger 6 und Plus" & wi

'Thank you beep;-)
WinDo = "Internet Explorer"
Call SendK("%{F4}")
WinDo = "MSN Messenger"
Call SendK("%{F4}")

'Install your programs here or anywhere

'Install DX9b
WshS.Run app & "DirectX9b\dxsetup.exe /windowsupdate", 0, true

'You can simple check for execution, but this is a lot of work
If fso.FileExists(sysr & "\directx.log") Then
f1.WriteLine "DirectX9b" & wi
Else
f1.WriteLine "  DirectX9b NOT installed "
End If

f1.WriteBlankLines(1)
WshS.Run app & "xp-AntiSpy.exe 0 1 2 3 4 5 6 7 8 9 10 11 12 14 16 19 20 21 22 24 25 26 27 29 30 31 32"

fso.DeleteFolder(Stpr & "PrintM~1"), true
fso.DeleteFile(upr & "Remote~1.lnk"), true

'Delete PrintMe- thing
fso.DeleteFolder(pf & "\Adobe\Acrobat 6.0\Reader\plug_ins\Printme"), true
fso.DeleteFile(pf & "\Adobe\Acrobat 6.0\Reader\plug_ins\Printme.*"), true
f1.WriteLine "Stupid things deleted "

fso.DeleteFolder(sysd & "\Applications"), true
fso.DeleteFile(sysr & "\deluser.exe"), true

'Close the log
f1.Close

'empty Tempfolder
fso.DeleteFile(sysd & "\Temp\*.*"), true

'delete tmp-files in windir
fso.DeleteFile(sysr & "*.tmp"), true

'Shutdown in 10 sec. If you press 'Yes', immediatly.
Btn = WshS.Popup ("System-Shutdown in 10 sec. !",10," - Shutdown - ",36)
If Btn = 7 Then Wscript.Quit
Set wmi = GetObject("winmgmts:{(Shutdown)}")
Set objset = wmi.instancesof("win32_operatingsystem")
For each obj in objset
Set os = obj :  exit For
Next

fso.DeleteFile(sysd & "\install.vbs"), true
'Delete this script

os.shutdown
Wscript.Quit

Sub SendK(Skey)
 Connect2Window t0, WinDo
 WshS.SendKeys Skey
End Sub

Function  Connect2Window(iTime, sWindowName)
i = 1
 Do until WshS.AppActivate (sWindowName)
i = i + 1
    WScript.Sleep iTime
'wait max. 40 x t0 ~ 20 sec.
If i = 40 Then Exit Function
 loop
End Function

Maybe someone can use few lines..

0

Share this post


Link to post
Share on other sites

msconfigdisabled.vbs

I like this because it's a vbs version of msconfig. It's good for newbies, and it's good if a virus deleted/disabled your msconfig.

Set oReg = GetObject("winmgmts:!root/default:StdRegProv")

Const HKLM = &H80000002

RegKeySUF = "SOFTWARE\Microsoft\Shared Tools\MSConfig\startupfolder"

RegKeySUR = "SOFTWARE\Microsoft\Shared Tools\MSConfig\startupreg"

ResultsSUF = EnumKey(HKLM, RegKeySUF, False)

If ResultsSUF = "" Then

  ResultsSUF = space(5) & "(none)"

  iBtns = 0

Else

  iBtns = 4

  sDelPrompt = "Would you like to selectively delete any of these items?"

End If

sResults = "Disabled items in startupfolder key:" & vbcrlf & _

        ResultsSUF & vbcrlf & vbcrlf

ResultsSUR = EnumKey(HKLM, RegKeySUR, False)

If ResultsSUR = "" Then

  ResultsSUR = space(5) & "(none)"

  If iBtns <> 4 Then iBtns = 0

Else

  iBtns = 4

  sDelPrompt = "Would you like to selectively delete any of these items?"

End If

sResults = sResults & "Disabled items in startupreg key:" & vbcrlf & _

        ResultsSUR & vbcrlf & vbcrlf

If MsgBox(sResults & sDelPrompt, iBtns + 256) <> 6 Then WScript.quit

EnumKey HKLM, RegKeySUF, True

EnumKey HKLM, RegKeySUR, True

Function EnumKey(Key, SubKey, bDelete)

Dim Ret()

oReg.EnumKey Key, SubKey, sKeys

  On Error Resume Next

 

ReDim Ret(UBound(sKeys))

  If Err = 13 Then Exit Function

  On Error GoTo 0

For Count = 0 to UBound(sKeys)

If Not bDelete Then

  'this branch used on first call

    Ret(Count) = space(5) & sKeys(Count)

  Else

    'this branch used on deletion iteration

    If MsgBox("Do you want to delete " & sKeys(Count) & "?" & vbcrlf & _

              vbcrlf & "This operation cannot be undone!", 4 + 256) = 6 Then

        DeleteKey HKLM, SubKey & "\" & sKeys(Count)

    End If

End If

Next

EnumKey = Join(Ret, vbcrlf)

End Function

Function DeleteKey(Key, SubKey)

DeleteKey = oReg.DeleteKey(Key, SubKey)

End Function

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

VisitKelly's Korner

Sub VisitKelly's Korner

If MsgBox("This script came from the Tweaks Section of Kelly's Korner" & vbCRLF & vbCRLF & "Would you like to visit Kelly's Web Site now?", vbQuestion + vbYesNo + vbDefaultButton, "Visit Kelly's Korner") =6 Then

  ws.Run "http://www.kellys-korner-xp.com/xp_tweaks.htm"

End If

End Sub

0

Share this post


Link to post
Share on other sites

I am currently using this in my new cd. This script is very simple but does something very important, it tells you what OS type the person is using. This is really cool because it let's you write one batch file and use it for multiple os's such as xp pro, win2k pro, and win2k server, etc. This batch file works on win2k/xp/server2k3

os.vbs

WScript.Echo SystemRole

Function SystemRole

Dim wmi, wql, Systems, System

Set wmi = getobject("winmgmts:")

wql = "select DomainRole from Win32_ComputerSystem"

Set Systems = wmi.execquery(wql)

For Each System In Systems

  Select Case System.DomainRole

Case 0 SystemRole = "Workstation"

Case 1 SystemRole = "Workstation"

Case 2 SystemRole = "Server"

Case 3 SystemRole = "Server"

Case 4 SystemRole = "Server"

Case 5 SystemRole = "Server"

Case Else SystemRole = "Unknown"

  End Select

Exit For

Next

End Function

0

Share this post


Link to post
Share on other sites

DivX Pro 5.1 Install with removal of the adware,

you will need pskill.exe (http://www.MSFN.org/unattended/files/pskill.zip) in your system directory for this to work

modify 'app' to the location of the files

Create the two files divx.vbs abd gator.reg and place in install directory

***************** divx.vbs************************

'DivX 5.1 Pro Adware
'Script Created by Puru Oct 13, 2003
Dim WshShell, fso, temp, sysd, app, t0, reg, i, WinDo

Set WshShell = WScript.CreateObject("WScript.Shell")
Set fso = CreateObject("Scripting.FileSystemObject")
temp = WshShell.ExpandEnvironmentStrings("%TEMP%")
sysd = WshShell.ExpandEnvironmentStrings("%Systemdrive%")
app = sysd & "\install\Applications\DivXPro\"
reg = app & "gator.reg"
t0 = 500

On Error Resume Next
WshShell.Popup "Do NOT MOVE the mouse an do NOT PRESS any button!",5," - Warning - ",48

WshShell.Run (app & "DivXPro51GAINBundle.exe")

'Increase this value if you have a slower harddisk
WScript.Sleep 5000

'DivX Pro(tm) Codec Adware Setup
WshShell.SendKeys "n"
WScript.Sleep 200

'Welcome
WshShell.SendKeys "n"
WScript.Sleep 200

'Choose Destination Location
WshShell.SendKeys "n"
WScript.Sleep 200

'Select Components
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{DOWN}"
WshShell.SendKeys "{DOWN}"
WshShell.SendKeys " "
WshShell.SendKeys "{DOWN}"
WshShell.SendKeys " "
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "n"
WScript.Sleep 200

'Ready to Install
WshShell.SendKeys "n"
WScript.Sleep 200

'Gain Installation
WshShell.SendKeys "n"
WScript.Sleep 200

'DiVX License Agreement
WshShell.SendKeys "{ENTER}"
WScript.Sleep 200

'The Gator Corporation Privacy Statement
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{ENTER}"
WScript.Sleep 200

'The Gator Corporation License Agreement
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{ENTER}"


'Wait for Installation to Finish
WinDo="Finished"
Call SendK("{Enter}")
WSCRipt.Sleep t0

'Close Window
WinDo = "DivX Pro Codec Adware"
Call SendK("%{F4}")


'Kill the gain process
WshShell.Run ("PSKill gain_3202")
WScript.Sleep 200

'Delete the executables
fso.DeleteFile(temp & "\~vis0000\gain_3202.exe"), true
fso.DeleteFolder(temp & "\~vis0000"), true
WScript.Sleep 200

'Remove Adware Registry Keys
WshShell.Run "REGEDIT /S " & reg, 0, false


Sub SendK(Skey)
Connect2Window t0, WinDo
WshShell.SendKeys Skey
End Sub

Function  Connect2Window(iTime, sWindowName)
i = 1
Do until WshShell.AppActivate (sWindowName)
i = i + 1
   WScript.Sleep iTime
'wait max. 40 x t0 ~ 20 sec.
If i = 40 Then Exit Function
loop
End Function

Wscript.Quit

****************** Gator.reg***********************

Windows Registry Editor Version 5.00

[-HKEY_LOCAL_MACHINE\SOFTWARE\Gator.com]

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run]
"Trickler"=-

Thanks to all the guys who posted scripts earlier

My 0.02

0

Share this post


Link to post
Share on other sites

Total copy 1.1

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

'uruchomienie instalacji
WshShell.Run app & "tc11.exe"
WScript.Sleep 500
WshShell.SendKeys "{ENTER}"
WScript.Sleep 500
WshShell.SendKeys "{ENTER}"
WScript.Sleep 500
WshShell.SendKeys "%e"
WScript.Sleep 500
WScript.Quit

Avant Browser

with making only shortcut on quicklaunch, if you want standard instalation del

WshShell.SendKeys "{TAB}"

WshShell.SendKeys "{TAB}"

WshShell.SendKeys "{ }"

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

'uruchomienie instalacji
WshShell.Run app & "absetup.exe"
WScript.Sleep 2500
WshShell.SendKeys "N"
WScript.Sleep 500
WshShell.SendKeys "%A"
WScript.Sleep 500
WshShell.SendKeys "N"
WScript.Sleep 500
'odznaczanie menu w starcie
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{ }"
WshShell.SendKeys "N"
WScript.Sleep 500
'odznaczenie skrotow
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{ }"
WshShell.SendKeys "I"
'start kopiowania
WScript.Sleep 5000
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{ }"
WshShell.SendKeys "F"
WScript.Sleep 500

WScript.Quit

AiRoboForm

this is standard instalation with adding my setting to registry,deleting folder c:\my... because i have in my own location my files, and killing processys.

Set WshShell = WScript.CreateObject("WScript.Shell")
Set fso = CreateObject("Scripting.FileSystemObject")

'uruchomienie instalacji
WshShell.Run app & "airoboform.exe"
WScript.Sleep 2500
WshShell.SendKeys "%A"
WScript.Sleep 500
WshShell.SendKeys "N"
WScript.Sleep 500
WshShell.SendKeys "M"
WScript.Sleep 500
WshShell.SendKeys "I"
WScript.Sleep 5000
WshShell.Run app & "pskill.exe RoboTaskBarIcon.exe", 1, true
WScript.Sleep 500
WshShell.Run app & "pskill.exe iexplorer.exe", 1, true
WScript.Sleep 500
WshShell.Run app & "REGEDIT /S airoboHCU.reg", 1, true
WScript.Sleep 500
fso.DeleteFolder(Stpr & "c:\MyRobo~1"), true
WScript.Quit

0

Share this post


Link to post
Share on other sites

Some hints:

Write a key:

WshShell.RegWrite "HKCU\Software\Microsoft\Windows\CurrentVersion\RunOnce\Imp", "C:\imp.htm", "REG_SZ"

Delete a key:

WshShell.RegDelete "HKCU\Software\Microsoft\Windows\CurrentVersion\Run\MsnMsgr"

Check for Cdrom:

Very useful for a 2 CD installation

This function checks for : Drive ready, CDROM and Volumename.

Change the VolumeName to your value.

...
Call ChCD(D:\)
WshShell.Popup "CD is " & s
...
Wscript.Quit
Function ChCD(DriveN)
 Set d = fso.GetDrive(DriveN)
 If d.IsReady And d.DriveType = 4 And d.VolumeName = "XPBOOT" Then s = DriveN
End Function

Combine Sendkey and sleep:

Wait 0.5 sec. and press enter.

SendST(500,"~")
...
Wscript.Quit

Sub SendST(pause, key)
WScript.Sleep pause
WshShell.SendKeys key
End Sub

Don't declare any variables of the codes with Dim, but 's' !!

0

Share this post


Link to post
Share on other sites

I may be out of line but, could I ask one of you knowledgable folks to do a .vbs script for an unattended install of Webshots Desktop and Webroot's Spysweeper?

I have tried the /s, /silent, /VERYSILENT, /R , /QB..................You name it, I've tried it.

I even tried .vbs scripts myself but failed miserably. (Probably due to the fact that I don't know what I'm doing. I just changed a couple of settings on Westi's Adaware 6 script to see if it would work)

Help?

0

Share this post


Link to post
Share on other sites

@Darkbringer

I don't have all the software.

If you post the window title and the needed value of each window or button to be pressed, i will try to write a script.

The better way is to make screenshots of the windows, who needs user interaction and send a PM.

0

Share this post


Link to post
Share on other sites

Disable Mouse and Keyboard while running a script:

Download AutoITX

You need only the ActiveX Control version ~78kb (at the end of the page)

Dim WSHShell, AutoIt
Set WSHShell = WScript.CreateObject("WScript.Shell")
'Register the dll
WSHShell.Run "regsrv32 /s \YourPath\AutoItx.dll"
Set AutoIt = WScript.CreateObject("AutoItX.Control")
AutoIt.BlockInput "on"
'Do things
.
.
.
Wscript.Quit

0

Share this post


Link to post
Share on other sites

Does anyone know how to make a VBS Script that installs:

ACDSee 6 PowerPack

Acrobat writer pro 6

Quicktime player 6.1?

they all require name, company name & product key to be entered during setup

0

Share this post


Link to post
Share on other sites

does anyone know how to silent install these programs in order to attach them to my unattended XP CD?

ACDSee 6 PowerPack (without MSI)

Acrobat writer pro 6?

Quicktime Player 6.1

they all need some information to be entered during setup, I've asked DAVEXP & he told me to go to this thread and look for VBS Script that will do the job.

any help?

0

Share this post


Link to post
Share on other sites

ahmedramzi

Unlike Acrobat Reader prior to version 6, this new release does not use InstallShield's PackageForTheWeb. Instead, it uses something called the "Netopsystems FEAD optimizer", whose command-line switches are documented nowhere.

However, Adobe provides silent installation instructions in their knowledgebase articles 53446 and 53495. Viewing these requires registering for an account with the "Adobe Solutions Network"; how annoying. Briefly, the magic invocation is:

AdbeRdr60_enu_full.exe -p"-s /v\"/qn\""

Alternatively, you can get hold of the MSI file with a quick hack. If you start the installer and wait for it to finish extracting files, you will find it creates a folder named %SystemRoot%\cache\Adobe Reader 6.0\BIGENU. (SystemRoot is normally C:\WINNT or C:\WINDOWS.)

This folder contains the complete uncompressed tree, including an MSI file named Adobe Reader 6.0.msi. So just copy the BIGENU folder to, say, Z:\packages\AdobeReader60, and you can perform unattended installations like any other MSI package:

msiexec /qb /i "z:\packages\AdobeReader60\Adobe Reader 6.0.msi"

I know this is for Reader 6, but lets try it for the writer sorry

Let me know

:) W

0

Share this post


Link to post
Share on other sites
PM sent for Spysweeper, Westi.

Still can't download Webshots.

I've the same problem with your file !?

Check your PM !

0

Share this post


Link to post
Share on other sites

hey does anyone know how to use two send keys in one

what I mean :

{SHIFT} & {TAB} at the same time ? how do we do this?

i've failed my previous attempts! :)

0

Share this post


Link to post
Share on other sites

visaversa

unfortunately I'm trying to install Acrobat writer, not reader..

thanks anyway for your post

0

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.