There are features in Vista that are NOT available in earlier version of Windows so there may be times when you need to know what OS your application is running under. Determining the OS version is as simple as checking the System.Environment.OSVersion object.
If System.Environment.OSVersion.Version.Major >= 6 Then
'Vista specific code here
'Earlier versions of Windows code here
There are a number of other useful pieces of information in the System.Environment namespace such as GetFolderPath which returns the path of the special system folder based on the enum specified. For example, this code returns the location of the My Documents folder.
x = System.Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments)
Have a day. :-|