I have a simple wpf application. But it is using CefSharp to open some links in chrome based browser. I found that once the main window of the application is closed, It is closed from the UI but it still runs in the background.
I tried adding additional code to force close it. but no hope. I think some components of cefsharp is not ending correctly. but not exactly sure on what is going wrong.
Used the below code and some other snippets too
protected override void OnClosed(EventArgs e)
foreach (Window w in App.Current.Windows)
if (w.DataContext != this)
As I said in my comment, try:
If that doesn't work, start with
If you REALLY need it to close out you can also use Environment.Exit() but it is not graceful at all (more like ending the process).