Jump to content

X86 and X64 on Win7


Recommended Posts

Initial had to differeniate between XP and Win 7 but now it seems some of the machine are win7 32bit.

Some reason a script using the @OSArch is failing on Win 732bit but works great on Win 7 64bit.

I did see there is the @CPUArch varible I can use but don't know if it will met my requirments.

Suggestions?

Local $OSVersion = @OSVersion ;Returns one of the following: "WIN_2008R2", "WIN_7", "WIN_2008", "WIN_VISTA", "WIN_2003", "WIN_XP", "WIN_XPe", "WIN_2000".

Local $OSArch = @OSArch ;Returns one of the following: "X86", "IA64", "X64" - this is the architecture type of the currently running operating system.

Local $CPUArch= @CPUArch;

Local $NetworkInstallerFullPath, $InstallerMSIFileName

Switch @CPUArch

Case "X64"

$InstallerMSIFileName = "Setup x64.msi"

$NetworkInstallerFullPath = @ScriptDir & "\" & $InstallerMSIFileName

Case "X86"

$InstallerMSIFileName = "Setup.msi"

$NetworkInstallerFullPath = @ScriptDir & "\" & $InstallerMSIFileName

Case Else

MsgBox(0, "Error has occured!", "Processor " & $CPUARCH & " type isn't supported!")

Exit(1603)

EndSwitch

Edited by want2becoder
Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...