I'm trying to retrieve the version number of various installed applications and then perform an action if they are lower than a certain value. For example:
Dim regKey As RegistryKey
Dim ver As ???????
regKey = Registry.LocalMachine.OpenSubKey("Software\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall\Adobe Flash Player ActiveX")
ver = regKey.GetValue("DisplayVersion")
MessageBox.Show(ver)
If ver < 11.4.402.287 Then
'Install updated version of software in question
End If
regKey.Close()
How could I define Ver to be able to easily do a greater/less than check? I've tried:
Dim ver as integer
Dim ver as decimal
Both of these return "Additional information: Conversion from string "11.4.402.287" to type 'Decimal' is not valid."