This has to be decided according to the steps in your installer. I can only give you a rough framework for you to modify yourself, because we also don't know exactly what kind of program you're installing, or how many steps the installer has. So I can only give you an example, and you can modify it based on that example. Below is a script for installing CCLEANER software.
http://www.ccleaner.com/ccdownload.asp This is the program download. This tool is pretty good; I've been using it for about 2 years already. It's a small program for cleaning junk files from the disk. Go to the page above and click "Alternative Download" to download it. Below is the VBS code:
option explicit
dim bagpipe,hi,ok
set bagpipe=createobject("wscript.shell")
hi=inputbox("Enter the full path of the program you want to run~~","Don't type it wrong, or it won't work!","Full path of the program")
set ok=bagpipe.exec(hi)
with bagpipe
wscript.sleep 1000
.appactivate ok.processid
.sendkeys "{ENTER}"
wscript.sleep 1000
.sendkeys "{ENTER}"
wscript.sleep 1000
.sendkeys "{ENTER}"
wscript.sleep 1000
.sendkeys "c:\test" 'this changes the program's default installation path to c:\test
wscript.sleep 1000
.sendkeys "{TAB 3}"
wscript.sleep 1000
.sendkeys "{ENTER}"
wscript.sleep 1000
.sendkeys "{ENTER}"
wscript.sleep 6000
.appactivate ok.processid
.sendkeys "{ENTER}"
end with