hasi001 Posted October 25, 2004 Posted October 25, 2004 Well the feature request that I have. Is to put in a configuration to specify the Os this app or Tweak is for. If OS=Win2k for example then install all those items. plus defaults.@all: Does anyone know, how to get Windows Version through WSH like "ver" in command prompt ? Registry Key ?Mod would be easy if I had this information.
a06lp Posted October 25, 2004 Posted October 25, 2004 @a06lp Would this help ?i feel kinda stupid. yea, that worked.i dont know why, but before the latest WPI my old code worked, but now it caused a reboot. in any case, the new code (below) solved the problemcmd1[pn]=['systemdrive','install\\Applications\\vegasvideo\\vegas.msi /qn REBOOT=Suppress']
shuter Posted October 25, 2004 Posted October 25, 2004 @all: Does anyone know, how to get Windows Version through WSH like "ver" in command prompt ? Registry Key ?hasi001, I'm not aware of an easy way to get the OS version through a simple script. You can find out if the OS is NT or 9x based through the %OS% system variable (not set in 9x), though, and check the system variable %windir% to determine if the system is Windows NT/2000 or XP, assuming you installed the operating system to the default location ( c:\windows versus c:\winnt).
djbe Posted October 25, 2004 Posted October 25, 2004 Djbe...you can do the following..i put all my applications to a folder APPS in my root dvd...when unattendend you call WPI as usual from $OEM$ and choose applications with %CDROM%\\APPS\\......Then i make an extra folder with WPI in root of DVD and i built an autorun menu than calls %CDROM%\WPI\WPI.hta.Here config.js has the same code like unattended WPI %CDROM%\\APPS\\......I think i helped you..sorry for my english ..Thanks Sj410, that's kinda what i needed just to know that with %cdrom%, i had to begin from the root of the cd
nivek7 Posted October 26, 2004 Posted October 26, 2004 Question: Is there a convertor out there that will convert to the config format from RunOnceEx? I really don't want to do it by hand.
dhernande Posted October 26, 2004 Posted October 26, 2004 strComputer = "."Set objWMIService = GetObject("winmgmts:" _ & "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")Set colOperatingSystems = objWMIService.ExecQuery _ ("Select * from Win32_OperatingSystem")For Each objOperatingSystem in colOperatingSystems Wscript.Echo objOperatingSystem.Caption & " " & _ objOperatingSystem.VersionNexthttp://www.microsoft.com/technet/scriptcen...n/ostveb01.mspx
hasi001 Posted October 26, 2004 Posted October 26, 2004 @nivek7:Since the machine can't read your brainwaves yet, you have to do some typing to inform it of the apps you want it to install. Your question indicates you have that information, but in another format. Give an example, be more specific what your needs are. What's the "config format from RunOnceEx" ??@dhernande:I saw such a thing once. People told me it wouldn't work on 95, 98, 98se or ME. Since I don't have any of there OSs installed I cannot check that, but perhaps you know it. In the end I'm not sure if the whole WPI thing would work on any of these old OSs.
Rodent Posted October 26, 2004 Posted October 26, 2004 Feature request:"Syntax Check of config.js"so I do not have to try it every time in VMware, before going live.Would be another great thing.Thanks Hasi for that great stuff you threw in!rgdsAlex
a06lp Posted October 26, 2004 Posted October 26, 2004 Feature request:"Syntax Check of config.js"so I do not have to try it every time in VMware, before going live.umm... if you just run wpi.hta (double click it), you'll know if it works or not...
Rodent Posted October 26, 2004 Posted October 26, 2004 hmmsilly me, no?sorry about that one...anyway,i ran into a problem...the last record pn my long list of apps always i listed two times in the WPI screen.Example:prog[pn]=['WS_FTP Pro 9.01']desc[pn]=['FTP Client']cmd1[pn]=['%cdrom%\\Install\\WS_FTPpro9.01\\fo-w901.exe -s']dflt[pn]=['yes']cat[pn]=['System']pn++makes WS_FTP be listed in "Systems group besides other Programs in Systen Group,and creates a second "System" Group at the end, only containing WS_FTP...any idea?thanksalex
hasi001 Posted October 26, 2004 Posted October 26, 2004 send me your whole config.js as pm so I can search for an error.Is sorting set to true ?
dhernande Posted October 26, 2004 Posted October 26, 2004 hasi001I wasnt to concerned about the following operating systemsmore along the lines of XP,2003,2000pro,2000 Serverthis is more for Registry keys and for server apps Some of the registry hacks I have wont appy to XP but they will apply in server
Rodent Posted October 26, 2004 Posted October 26, 2004 sorting is true,will try it again with set to false,but in advance you get my config.js with pmanother question:how do i setup WPI,if i want to execute WPI installing Software from C:\Install on a virtual machine,if variables are set to %cdrom%Would be the win51 file on C:\ enough,to get WPI take the %cdrom% as C:\ ?thanksalex
Rodent Posted October 26, 2004 Posted October 26, 2004 ok,if set to false,I do not get the double entry,but I really would prefer to go with sorting=truethanks hasirgdsalex
hasi001 Posted October 26, 2004 Posted October 26, 2004 dhernande: so we're going to speak of the 'modern' operating systems XP Pro, XP Home, 2003 Server, 2K Pro, 2k Server - am I wrong ?If you look at the registry keys in HKLM\\Software\\Microsoft\\Windows NT\\CurrentVersion what's the differences that decide if its a server-version or not. I only have XP Pro, where ProductName="Microsoft Windows XP" and CurrentVersion="5.1"I know 5.1 stands for XP, 5.0 for 2k and 4.0 for NT, but what differs 2k from 2k Server and what's the values for 2k3 ?
Recommended Posts