Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Check Operating System (OS)
- Dim Full_Os_Name As String = My.Computer.Info.OSFullName
- Dim User_Os As String
- Sub Get_OS_NAME()
- If Full_Os_Name.Contains("Windows 7") Then
- User_Os = "Windows 7"
- ElseIf Full_Os_Name.Contains("Windows Vista")Then
- User_Os = "Windows Vista"
- ElseIf Full_Os_Name.Contains("Windows XP")Then
- User_Os = "Windows XP"
- Else
- MessageBox.Show(Full_Os_Name & " is not supported by: " & My.Application.Info.ProductName & ", Version " & My.Application.Info.Version.ToString)
- Application.Exit()
- End If
- 'Label3.Text = ("OS: " & User_Os)
- End Sub
- Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
- Get_OS_Name()
- End Sub
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement