• 0

A newbie question about C#


Question

4 answers to this question

Recommended Posts

  • 0
Sample Command Lines

Compiles File.cs producing File.exe:

csc File.cs

Compiles File.cs producing File.dll:

csc /target:library File.cs

Compiles File.cs and creates My.exe:

csc /out:My.exe File.cs

Compiles all of the C# files in the current directory, with optimizations on and defines the DEBUG symbol. The output is File2.exe:

csc /define:DEBUG /optimize /out:File2.exe *.cs

Compiles all of the C# files in the current directory producing a debug version of File2.dll. No logo and no warnings are displayed:

csc /target:library /out:File2.dll /warn:0 /nologo /debug *.cs

Compiles all of the C# files in the current directory to Something.xyz (a DLL):

csc /target:library /out:Something.xyz *.cs

Link to comment
Share on other sites

  • 0
you need to set csc.exe as an environment variable first, if it hasn't been already, then what weenur said.

:huh: No, if anything you need to make sure the folder csc.exe resides in is in the PATH variable.

Link to comment
Share on other sites

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.