How to enable Adobe Flash with CefSharp?

I am using the latest version of CefSharp and I need to display Flash. When using Chrome, the page displays correctly. However, using CefSharp is not the case.

So far I have tried:

var browser = new ChromiumWebBrowser(URL) { BrowserSettings = new BrowserSettings() { Java = CefState.Enabled, Plugins = CefState.Enabled, }, Dock = DockStyle.Fill }; 

When I download about:plugins , I get:

CEF 3.2357.1287.g861c26e

Chromium 43.0.2357.130

Windows OS

WebKit 537.36

JavaScript 4.3.61.30

Flash

Mozilla / 5.0 user agent (Windows NT 6.2, Win64; x64) AppleWebKit / 537.36 (KHTML, e.g. Gecko) Chrome / 43.0.2357.130 Safari / 537.36

How to enable Flash in CefSharp?

+5
source share
2 answers

I solved this problem with the following steps:

1-) I downloaded the pepflashplayer plugin from this URL: https://www.dllfiles.com/pepflashplayer.dll.html

2-) I added these CefCommandLineArgs to CefSettings: settings.CefCommandLineArgs.Add ("enable-npapi", "1");

settings.CefCommandLineArgs.Add ("ppapi-flash-path", flashPluginPath);

settings.CefCommandLineArgs.Add ("ppapi-flash version", "20.0.0.306");

flashPluginPath is the path where pepflashplayer.dll is located, and "20.0.0.306 is the plugin version. I am using cefsharp version 53

+1
source

Source: https://habr.com/ru/post/1233040/


All Articles