This example displays the current operating system and version number. To run this example, put a SysInfo control and a CommandButton control on a form. Then paste the example into the form's Declarations section, run the project and click the CommandButton.
Private Sub Command1_Click()
Dim MsgEnd As String
Select Case SysInfo1.OSPlatform
Case 0
MsgEnd = "Unidentified"
Case 1
MsgEnd = "Windows 95, ver. " & CStr(SysInfo1.OSVersion)
Case 2
MsgEnd = "Windows NT, ver. " & CStr(SysInfo1.OSVersion)
End Select
MsgBox "System: " & MsgEnd
End Sub