I want to check from my code if a particular version of flash player is installed or not.
I used the following code
using Microsoft.Win32
RegistryKey RK = Registry.CurrentUser.OpenSubKey("HKEY_LOCAL_MACHINE\\SOFTWARE\\Macromedia\\FlashPlayer");
if (RK != null)
{
// It's there
}
else
{
// It's not there
}
In registry If I search for flash player with version 10.2.161.23, the location
“HKEY_LOCAL_MACHINE\SOFTWARE\Macromedia”
is having 2 folders:
- FlashPlayer and
- FlashPlayerActiveX.
But, my above code is not working.
Kindly let me know how to check if a particular version of flash player is installed in a system or not USING C#.NET.
Adobe’s old (pre 10) IE Flash detection code used to test in VBScript if it could instantiate object ShockwaveFlash.ShockwaveFlash.<major version>. If it’s just the major version you want to test, you can check for those keys under HKCR, e.g.
HKEY_CLASSES_ROOT\ShockwaveFlash.ShockwaveFlash.10.SWFObject instantiates the version-less object name, ShockwaveFlash.ShockwaveFlash, and queries its
$versionproperty. To do this in C#: