How can I make my application check if Adobe flash player is installed on a PC?

自作多情 提交于 2019-12-02 01:39:34

Check if this registry key exists:

\HKEY_LOCAL_MACHINE\SOFTWARE\Macromedia\FlashPlayer

Then, you can check the installed version (if installed) from here:

\HKEY_LOCAL_MACHINE\SOFTWARE\Macromedia\FlashPlayer\CurrentVersion

Here you can find code on how to check existence of registry key.

Following code return current version string of flash.

private string GetFlashPlayerVersionString()
{
    RegistryKey regKey = Registry.LocalMachine.OpenSubKey(@"SOFTWARE\Macromedia\FlashPlayer");
    if (regKey != null)
    {
        string flashVersion = Convert.ToString(regKey.GetValue("CurrentVersion"));
        return flashVersion;
    }
    return string.Empty;
}

Open the Flash folder (C:\Windows\System32\Macromed\Flash) and whatever is listed there would be your Flash Player files.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!