Answer the question
In order to leave comments, you need to log in
CS5001. Does the program not contain a static "Main" method suitable for the entry point?
program.cs
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace WindowsFormsApplication2
{
static class Program
{
/// <summary>
/// Главная точка входа для приложения.
/// </summary>
[STAThread]
static void Main()
{
Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
Application.Run(new Form1());
}
}
}
public Form1()
{
InitializeComponent();
}
Answer the question
In order to leave comments, you need to log in
In the project properties, set the entry point
And yes, add public for the class and for the Main method
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question