|
|
|||||||
I had this running in a script to determine the OS. Now that is switched from kixtart 3.63 4.02 it doesn't work anymore. I know there are a lot of ways to do this but some are way too long. I just want to simply know the OS type. Here is what I have: Select Case ((@INWIN = 1) And (@DOS = 5.0)) $OS = "Win2K" Case ((@INWIN = 1) And (@DOS = 4.0)) $OS = "WinNT4" Case ((@INWIN = 2) And (@DOS >= 4.10)) $OS = "Win98" Case ((@INWIN = 2) And (@DOS = 4.0)) $OS = "Win95" EndSelect "Running""$os" On 3.62 the output wass fine. On 4.02 I get $os as the output. Thanks |
||||||||
|
|
|||||||
I didn't test this on Win98, but try this... ? "[ @INWIN ][ @DOS ]" ? "" SELECT CASE((@INWIN = "1") And (@DOS = "5.0")) $OS = "Win2K" CASE((@INWIN = "1") And (@DOS = "4.0")) $OS = "WinNT4" CASE((@INWIN = "2") And (@DOS > "4.0")) $OS = "Win98" CASE((@INWIN = "2") And (@DOS = "4.0")) $OS = "Win95" ENDSELECT ? "Running " + "$os" ? "" Rocco [ 11 April 2002, 17:31: Message edited by: Rocco Capra ] |
||||||||
|
|
|||||||
Try this: code:Also, take a look at the @PRODUCTTYPE, that'll give you a little bit more granularitySelect [ 11 April 2002, 17:28: Message edited by: sealeopard ] |
||||||||
|
|
|||||||
The @DOS macro returns a text string so put quotes around your numbers like @DOS = "5.0". You may also want to add a "CASE 1" at the end of your select to catch any unexpected data. [ 11 April 2002, 17:54: Message edited by: Howard Bullock ] |
||||||||
|
|
|||||||
Thanks everyone!! |
||||||||
|
|
|||||||
Dear, A more complete script can be: code:greetings.$os="" |
||||||||
|
|
|||||||
Use the new @producttype command available in KIX v4.x. It's really more simple than the @inwin and @dos in the script. Try: IF @PRODUCTTYPE = "Windows 95" Blah, Blah... ENDIF There is a list of @PRODUCTTYPE in the KIX manual. |