| View previous topic :: View next topic |
| Author |
Message |
TheLeO
Joined: 11 Jun 2005 Posts: 264 Location: England ish
|
Posted: Tue Feb 09, 2010 7:42 am Post subject: How do you know if an os is 64 or 32 bit? |
|
|
Hello
Is there a build in variable or some way my script can tell if you're using a 64 bit software or 32 bit, (and works fine on multilingual windows systems)?
Reason beihing, I need it to to delete a registry entry, but it's on different places on the 64 and 32 bit systems.
I could of course attempt to delete both, but that wouldn't be very neat.
Leo.. _________________ ::
I Have Spoken
:: |
|
| Back to top |
|
 |
doyle
Joined: 14 Nov 2007 Posts: 325 Location: London, England
|
Posted: Tue Feb 09, 2010 9:12 am Post subject: |
|
|
| Code: | ThisProcess := DllCall("GetCurrentProcess")
; If IsWow64Process() fails or can not be found,
; assume this process is not running under wow64.
; Otherwise, use the value returned in IsWow64Process.
if !DllCall("IsWow64Process", "uint", ThisProcess, "int*", IsWow64Process)
IsWow64Process := false
MsgBox % IsWow64Process ? "win64" : "win32" |
Thanks to lexikos. |
|
| Back to top |
|
 |
TheLeO
Joined: 11 Jun 2005 Posts: 264 Location: England ish
|
Posted: Tue Feb 09, 2010 7:39 pm Post subject: |
|
|
this works thank you.
Leo. _________________ ::
I Have Spoken
:: |
|
| Back to top |
|
 |
|