Results 1 to 5 of 5

Thread: Who has all MS Windows version numbers??

  1. #1

    Thread Starter
    Member
    Join Date
    Oct 2000
    Location
    Netherlands
    Posts
    54

    Question

    Can anyone help me to get all the current Windows versions? Preferably even after a SP has ben applied if the version number changed.

    There are so many, and they some want their API stuff different. So versions numbers of Windows 95/98/98SE/98ME/NT351/NT4/W2000

    Wish I had such a version history
    A mind is like a parachute, it has to open to let it work
    www.2beesoft.com for Icon Manager with over 20.000 free icons
    VB6 Ent. SP4, ASP, W2000/W98

  2. #2
    Serge's Avatar
    Join Date
    Feb 1999
    Location
    Scottsdale, Arizona, USA
    Posts
    2,744
    You can easily find that out:
    Code:
    Option Explicit
    Private Type OSVERSIONINFO
            dwOSVersionInfoSize As Long
            dwMajorVersion As Long
            dwMinorVersion As Long
            dwBuildNumber As Long
            dwPlatformId As Long
            szCSDVersion As String * 128      '  Maintenance string for PSS usage
    End Type
    Private Declare Function GetVersionEx Lib "kernel32" Alias "GetVersionExA" (lpVersionInformation As OSVERSIONINFO) As Long
    Private Const VER_PLATFORM_WIN32_NT = 2
    Private Const VER_PLATFORM_WIN32_WINDOWS = 1
    
    Public Function GetWindowsVersion() As String
        Dim os As OSVERSIONINFO
        Dim strVersion As String
        Dim strSP As String
        
        os.dwOSVersionInfoSize = Len(os)
        os.szCSDVersion = Space(255)
        Call GetVersionEx(os)
    
    
        With os
            Select Case .dwPlatformId
                Case VER_PLATFORM_WIN32_WINDOWS
                    If .dwMinorVersion = 0 Then
                        strVersion = "Windows 95"
                    ElseIf .dwMinorVersion = 10 Then
                        strVersion = "Windows 98"
                    End If
                    
                Case VER_PLATFORM_WIN32_NT
                    If .dwMajorVersion = 3 Then
                        strVersion = "Windows NT 3.51"
                    ElseIf .dwMajorVersion = 4 Then
                        strVersion = "Windows NT 4.0"
                    ElseIf .dwMajorVersion = 5 Then
                        strVersion = "Windows 2000"
                    End If
                    
                    strSP = Trim(.szCSDVersion)
            End Select
            
            strVersion = strVersion & vbCrLf & .dwMajorVersion & "." & .dwMinorVersion & "." & .dwBuildNumber
            strVersion = strVersion & vbCrLf & strSP
        End With
        
        GetWindowsVersion = strVersion
    End Function
    
    
    Private Sub Form_Load()
        MsgBox GetWindowsVersion
    End Sub

  3. #3
    Fanatic Member
    Join Date
    Feb 2000
    Location
    The Netherlands
    Posts
    715
    Serge, does it return 'Windows 98', if ME is installed?
    Oetje
    [email protected]
    93606776
    Visual Basic 6, Windows 2000

    Never pet a burning dog

  4. #4
    Serge's Avatar
    Join Date
    Feb 1999
    Location
    Scottsdale, Arizona, USA
    Posts
    2,744
    Actually I'm not sure, since I don't have WindowsME installed (and I dont know any one who does). But what you can do is to check if the dwMajorVersion has changed.
    If it's not, then dwMinorVersion will be changed for sure.

    Regards,

  5. #5
    Fanatic Member
    Join Date
    Feb 2000
    Location
    The Netherlands
    Posts
    715
    Thanks Serge.
    Oetje
    [email protected]
    93606776
    Visual Basic 6, Windows 2000

    Never pet a burning dog

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width