简体   繁体   中英

Program does not contain a suitable 'Main' method for entry point

I accidentally deleted the auto generated main entry point of my project. The problem is that I did not realised that and saved the changes and exit de program. Now I have the same error even if I create a new class and a new Main method. The error points to CSC file, but it won' t open anynthin when clicked. I remember that I somehow oppened the CSC file and deleted all the content inside. If you have any ideas or suggestion please respond! Thank you! 这是我收到的错误消息

Just create a new Project and if you need the Code of the Program where the Error was copy it and paste it in the new Project

Edit: If it's an WPF Projects copy the XAML codes

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM