如何不使用visual studio编译和运行c#程序? [英] How can I compile and run c# program without using visual studio?
本文介绍了如何不使用visual studio编译和运行c#程序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我是C#的新手。我已经使用Visual Studio运行C#'Hello World'程序。
我可以不使用Visual Studio运行或编译C#程序吗?
$ b
感谢
解决方案
如果您安装了.NET v4(因此如果您有更新的窗口或者您应用了Windows更新)
C:\Windows \Microsoft.NET\Framework\v4.0.30319\csc.exe nomefile.cs
或
C:\Windows \Microsoft.NET \ Framework \v4.0.30319\msbuild.exe nomefile.sln
或
C:\Windows \Microsoft.NET\Framework\v4.0.30319\msbuild.exe nomefile.csproj
很有可能如果你安装了.NET,%FrameworkDir%
变量已设置,因此:
%FrameworkDir%\v4.0.30319\csc.exe ...
%FrameworkDir%\v4.0.30319\msbuild.exe ...
I am very new to C#. I have just run C# 'Hello World' program using Visual Studio.
Can I run or compile a C# program without using Visual Studio?
If it is possible, then which compiler should I use?
Thanks
解决方案
If you have the .NET v4 installed (so if you have a newer windows or if you apply the windows updates)
C:\Windows\Microsoft.NET\Framework\v4.0.30319\csc.exe nomefile.cs
or
C:\Windows\Microsoft.NET\Framework\v4.0.30319\msbuild.exe nomefile.sln
or
C:\Windows\Microsoft.NET\Framework\v4.0.30319\msbuild.exe nomefile.csproj
It's highly probable that if you have .NET installed, the %FrameworkDir%
variable is set, so:
%FrameworkDir%\v4.0.30319\csc.exe ...
%FrameworkDir%\v4.0.30319\msbuild.exe ...
这篇关于如何不使用visual studio编译和运行c#程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文