|
-
Jul 26th, 2001, 08:26 AM
#1
Thread Starter
New Member
determine OS
I need some help finding an API call that will return the OS that is running on the machine. I've found just about every piece of info about the OS, but not which OS (NT, 95, 98, etc)...I'm about to go insane!!!
-
Jul 26th, 2001, 09:31 AM
#2
Hyperactive Member
this project will tell you if it is windows 9x or NT
works on NT,95,98,2000,XP
hope this helps you
Jason
-
Jul 26th, 2001, 04:38 PM
#3
Hyperactive Member
Code:
'put this in a module
Declare Function GetVersionEx Lib "kernel32.dll" Alias "GetVersionExA" (lpVersionInformation As OSVERSIONINFO) As Long
Type OSVERSIONINFO
dwOSVersionInfoSize As Long
dwMajorVersion As Long
dwMinorVersion As Long
dwBuildNumber As Long
dwPlatformId As Long
szCSDVersion As String * 128
End Type
Code:
'displays the major and minor version numbers of windows
'for example, 4.0 represents windows 95
Dim os As OSVERSIONINFO, retval As Long
os.dwOSVersionInfoSize = Len(os)
retval = GetVersionEx(os)
Debug.Print "Windows version number:"; os.dwMajorVersion; "."; os.dwMinorVersion
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|