我遇到的问题是试图找到项目中多个类的运行顺序。没有明确的 main,我查看了 obj/debug,没有发现任何可能在编译时生成的东西。你有什么想法我可能会找到一些东西。我也找不到任何 xaml 文件。这是一个控制台功能。
最佳答案
这是找到入口点(如果有的话)的快速方法:
在没有打开任何特定源文件的情况下,按 F11 在第一行启动调试器。这应该使您的切入点显而易见。
请注意,如果这是您所说的控制台应用程序,则必须有一个 static
main() 方法。
这是 Main()
的文档:
The Main method is the entry point of a C# console application or windows application. (Libraries and services do not require a Main method as an entry point.). When the application is started, the Main method is the first method that is invoked.
关于c# - c# 项目中没有 main(),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19163468/