The main method in WPF application lies in the file App.g.cs located at obj\\debug.This is autogenerated and will not be visible until we press the ‘Show all files’ button in the solution explorer.
[http://joyfulwpf.blogspot.com/2009/05/where-is-main-method-in-my-wpf.html]
Code generation of App.g.cs will not occur in Visual Studio 2008 when App class is not defined with the partial keyword.