In my case, I wanted to debug my edmx CodeGen but you can do it for a lot of other cases. So how to debug your CodeGen? I think there is probably a better way but this is what I did: In my CodeGen, I put a MessageBox.Show I open 2 VS: one with my CodeGen...