It does start on my main that I made it on. I tested on Win7, my main is Wi10 and my friend also tested it on Win10. First, I got this error: Error that I'd recieved and then I read that it can be fixed by setting "Copy local" true in all of the CefSharp reference properties. After that my program just stops working instantly and now it just doesn't start it only shows the crashing if I start it as admin. It still works on my main tho. And the code is nothing too extreme I just included the browser and disabled the right click.
public ChromiumWebBrowser browser;
public void InitBrowser()
{
Cef.Initialize(new CefSettings());
browser = new ChromiumWebBrowser("http://google.com/");
this.Controls.Add(browser);
browser.Dock = DockStyle.Fill;
browser.MenuHandler = new CustomMenuHandler();
}
public class CustomMenuHandler : CefSharp.IContextMenuHandler
{
public void OnBeforeContextMenu(IWebBrowser browserControl, IBrowser browser, IFrame frame, IContextMenuParams parameters, IMenuModel model)
{
model.Clear();
}
public bool OnContextMenuCommand(IWebBrowser browserControl, IBrowser browser, IFrame frame, IContextMenuParams parameters, CefMenuCommand commandId, CefEventFlags eventFlags)
{
return false;
}
public void OnContextMenuDismissed(IWebBrowser browserControl, IBrowser browser, IFrame frame)
{
}
public bool RunContextMenu(IWebBrowser browserControl, IBrowser browser, IFrame frame, IContextMenuParams parameters, IMenuModel model, IRunContextMenuCallback callback)
{
return false;
}
}