#35554 - 2003-01-23 10:38 AM
How best to determine OS?
|
R. Baker
Fresh Scripter
Registered: 2003-01-23
Posts: 7
|
I am writing a script to copy files to client PCs. I have to put the files in different directories depending on the operating system. I need to cater for everything from Win95, 98, ME, 2K and XP. "INWIN" seems to be inadequate. Is there a way to find this out?
Thanks,
R. Baker
|
|
Top
|
|
|
|
#35559 - 2003-01-23 02:54 PM
Re: How best to determine OS?
|
Kdyer
KiX Supporter
   
Registered: 2001-01-03
Posts: 6241
Loc: Tigard, OR
|
Another option is to use the Macros - @PRODUCTTYPE and/or @PRODUCTSUITE...
For example with @PRODUCTTYPE: quote:
OS type. Possible values: "Windows 95" "Windows 98" "Windows Me" "Windows NT Workstation" "Windows NT Server" "Windows NT Domain Controller" "Windows 2000 Professional" "Windows 2000 Server" "Windows 2000 Domain Controller" "Windows XP Home Edition" "Windows XP Professional" "Windows .Net Server" "Windows .Net Domain Controller"
If you are not running Kix 4.x or better, you can also use - http://home.wanadoo.nl/scripting/download/os.kix
HTH,
Kent [ 23. January 2003, 14:56: Message edited by: kdyer ]
|
|
Top
|
|
|
|
#35563 - 2003-01-23 07:54 PM
Re: How best to determine OS?
|
Radimus
Moderator
   
Registered: 2000-01-06
Posts: 5187
Loc: Tampa, FL
|
SInce everyone is getting into this, I thought I'd get on too.
Is the copy going remotely (i.e. push the files out to the remote PC) or from a script running local on the PC.
If it is local, then you may have security issues copying to %windir%.
But since the poster has abandoned the thread, it may be time to get off now...
|
|
Top
|
|
|
|
#35567 - 2003-01-23 08:15 PM
Re: How best to determine OS?
|
Radimus
Moderator
   
Registered: 2000-01-06
Posts: 5187
Loc: Tampa, FL
|
If you spoke as much as you type, you might be a huge contributer to green house gasses
No Lonk, that is not the way to bring an early spring to Finland.
|
|
Top
|
|
|
|
#35572 - 2003-01-23 09:23 PM
Re: How best to determine OS?
|
Radimus
Moderator
   
Registered: 2000-01-06
Posts: 5187
Loc: Tampa, FL
|
it is getting the coldest is has been here in several years...
They say it will drop below freezing for most of the local region sometime tonight.
I have to go out and cover my orange and lime trees so the frost won't kill the leaves.
|
|
Top
|
|
|
|
Moderator: Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart
|
0 registered
and 2220 anonymous users online.
|
|
|