【问题标题】:Program does not contain a static 'Main' method suitable for an entry point ///程序不包含适合入口点的静态“Main”方法 ///
【发布时间】:2018-08-30 10:09:12
【问题描述】:

出现此错误时我该怎么办?

"Severity   Code    Description Project File    Line    Suppression State
Error   CS5001  Program does not contain a static 'Main' method suitable for an entry point exercise 1  C:\Users\yona\source\repos\exercise 1\exercise 1\CSC    1   Active"

【问题讨论】:

    标签: compiler-errors


    【解决方案1】:

    您的项目可能被配置为可执行文件。在这种情况下,它希望有一个 main() 方法作为入口点。
    如果应用程序配置为库(动态或静态),则它不需要默认入口点,这意味着您不需要 main() 方法。

    【讨论】:

      猜你喜欢
      • 2012-04-21
      • 1970-01-01
      • 2013-06-10
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多