Click here to Skip to main content
15,127,310 members
Articles / Programming Languages / C#
Alternative
Tip/Trick
Posted 18 Sep 2010

Tagged as

Stats

10.1K views
2 bookmarked

32-Bit or 64-bit OS ??

Rate me:
Please Sign up or sign in to vote.
1.00/5 (3 votes)
20 Sep 2010CPOL
To check 64Bit Operating system in VB.NET,Public Shared Function is64BitOPeratinSystem() As Boolean Return (Marshal.SizeOf(IntPtr.Zero) = 8)End Function
To check 64Bit Operating system in VB.NET,

Public Shared Function is64BitOPeratinSystem() As Boolean
    Return (Marshal.SizeOf(IntPtr.Zero) = 8)
End Function

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Share

About the Author

a_pess
Engineer
Egypt Egypt
Oil & Gas Engineer
C# & VB.net
Coding For Fun Only

Comments and Discussions

 
GeneralReason for my vote of 1 This will always return 4 and the re... Pin
Member 740216616-Aug-11 0:23
MemberMember 740216616-Aug-11 0:23 
GeneralReason for my vote of 1 wrong - man test it before posting Pin
johannesnestler14-Oct-10 4:56
Memberjohannesnestler14-Oct-10 4:56 
GeneralReason for my vote of 1 False Pin
Toli Cuturicu11-Oct-10 12:38
MemberToli Cuturicu11-Oct-10 12:38 
Reason for my vote of 1
False
GeneralThis will always return 4! even if it is compiled in x64 mod... Pin
GPUToaster™21-Sep-10 1:51
MemberGPUToaster™21-Sep-10 1:51 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.