How to fix WPF error: "Program does not contain a static 'Main' method suitable for an entry point"? How to fix WPF error: "Program does not contain a static 'Main' method suitable for an entry point"? wpf wpf

How to fix WPF error: "Program does not contain a static 'Main' method suitable for an entry point"?


Check the properties of App.xaml. Is the Build Action still ApplicationDefinition?


Maybe the "Output type" in properties->Application of the project must be a "Class Library" instead of console or windows application.


Just in case anyone is having the same problem... I was getting this error, and it turned out to be my <Application.Resources> in my App.xaml file. I had a resource outside my resource dictionary tags, and that caused this error.