D
D
dpushin12021-03-23 16:03:13
C++ / C#
dpushin1, 2021-03-23 16:03:13

Is /main not allowed when building a module or library?

I got an error "it is not allowed to specify /main when building a module or library", how to fix it?
The code:

internal static class Program
  {
    [STAThread]
    private static void Main()
    {
      Application.EnableVisualStyles();
      Application.SetCompatibleTextRenderingDefault(false);
      Application.Run(new auth());
    }

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
Vasily Bannikov, 2021-03-23
@dpushin1

Your project seems to be of the "library" type. You need to make the type be "Executable something there"

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question