Larva King
06-12-2007, 09:02 PM
What would the syntax be for an open file command to only open that file if it is a (x86 or x64) OS.
Desolator
06-13-2007, 12:29 AM
Here you are:
if System.Is64BitOS() == true then
--[[
you can use File.Run, too, but if you don't need to get the return code
use Shell.Execute as File.Run can fail on Vista because of UAC
--]]
Shell.Execute( "AutoPlay\\Docs\\x64.exe", "open", "", "", SW_SHOWNORMAL);
else
Shell.Execute( "AutoPlay\\Docs\\x86.exe", "open", "", "", SW_SHOWNORMAL);
end
output enhanced with AMS Code Pretty (http://www.indigorose.com/forums/showthread.php?t=19409)
Powered by vBulletin™ Version 4.0.6 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.