Question

Is there a way to compile c# code w/in SharpDevelop (also applies to visual studio)? I am currently using DOS to do it, which seems inefficient.

EDIT: In other words, how do I do the equivalent of 'c:\windows\microsoft.net\framework\v2.0.50727\csc.exe /target:library /reference:ExcelDna.Integration.dll TestLib.cs' in sharp develop?

Was it helpful?

Solution

Let me count the ways (in Visual Studio - in SharpDevelop I bet you can look under the Build menu)

  1. Use the Build Menu and select Build Solution
  2. Hit F6
  3. Debug->Start Debugging (automatically will build first)
  4. Hit F5
  5. Right Click on Solution in Solution Explorer and select Build Solution
  6. Right click on project in Solution exploer and select Build Project.

and I'm sure there are more...

I do remember a long time ago I used to look for a way to actually compile a single file but then I quit looking. The syntax checker is so good (especially with ReSharper) that its not necessary, and the build process tends to be extremely fast.

EDIT --see comment Here's a screenshot of the popup you can use to change a project from a Windows Application to a Class Library. If you are in a file from the project you can also get to this view by selecting the last item from the Project menu (it has your project name and the suffix Properties...) enter image description here

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top