Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. error CS5001: Program does not contain a static 'Main' method suitable for an entry point

error CS5001: Program does not contain a static 'Main' method suitable for an entry point

Scheduled Pinned Locked Moved C / C++ / MFC
help
5 Posts 5 Posters 11 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • P Offline
    P Offline
    Pieter Claassens
    wrote on last edited by
    #1

    Tried these...

    public class Program {
    static async Task Main()
    { }
    }
    static int Main()
    {

    No luck , I'm afraid ...

    Mircea NeacsuM L D 3 Replies Last reply
    0
    • P Pieter Claassens

      Tried these...

      public class Program {
      static async Task Main()
      { }
      }
      static int Main()
      {

      No luck , I'm afraid ...

      Mircea NeacsuM Offline
      Mircea NeacsuM Offline
      Mircea Neacsu
      wrote on last edited by
      #2

      I'm afraid you will have to learn basic syntax of C++ language. Get a good book and start going through it.

      Mircea

      1 Reply Last reply
      0
      • P Pieter Claassens

        Tried these...

        public class Program {
        static async Task Main()
        { }
        }
        static int Main()
        {

        No luck , I'm afraid ...

        L Offline
        L Offline
        Lost User
        wrote on last edited by
        #3

        You already posted this question at Error CS5001: program does not contain a static 'main' method suitable[^], and received explanations of how to correct it. Please do not crosspost.

        1 Reply Last reply
        0
        • P Pieter Claassens

          Tried these...

          public class Program {
          static async Task Main()
          { }
          }
          static int Main()
          {

          No luck , I'm afraid ...

          D Offline
          D Offline
          Dave Kreskowiak
          wrote on last edited by
          #4

          That's C# code, not C/C++. You posted this in the wrong forum. But I see you already posted this elsewhere and received answers to it, so reposting this was redundant.

          Asking questions is a skill CodeProject Forum Guidelines Google: C# How to debug code Seriously, go read these articles. Dave Kreskowiak

          D 1 Reply Last reply
          0
          • D Dave Kreskowiak

            That's C# code, not C/C++. You posted this in the wrong forum. But I see you already posted this elsewhere and received answers to it, so reposting this was redundant.

            Asking questions is a skill CodeProject Forum Guidelines Google: C# How to debug code Seriously, go read these articles. Dave Kreskowiak

            D Offline
            D Offline
            David Crow
            wrote on last edited by
            #5

            Dave Kreskowiak wrote:

            ...so reposting this was redundant.

            And completely unnecessary.

            "One man's wage rise is another man's price increase." - Harold Wilson

            "Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons

            "You can easily judge the character of a man by how he treats those who can do nothing for him." - James D. Miles

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups