Command line compiling VB.NET project via Visual S

2020-04-11 09:54发布

I am trying to compile my Visual Basic .NET project named Myproject.sln via command line commands. I need to build and compile that solution.

My Visual Basic .NET compiler is called vbc.exe. Any idea how I do that thing?

I am using Visual Studio 2005 , and I have already read Microsoft's tutorial, "Building from the Command Line (Visual Basic)".

3条回答
别忘想泡老子
2楼-- · 2020-04-11 10:14

Just run MSBuild and specify the .sln file as a command line option:

msbuild myproject.sln /p:buildmode=release
查看更多
Explosion°爆炸
3楼-- · 2020-04-11 10:22

You could look at using MSBuild. That's probably the best approach.

Your .sln file is a valid MSBUild project file, so if you open the Visual Studio command prompt from the start menu and browse to your project location,

 c:\...\msbuild MyFile.sln

... for example, it should just work.

查看更多
ら.Afraid
4楼-- · 2020-04-11 10:34

The .NET framework (version 2 and above) comes with a command line build utility called MSBuild. You can use this to build your Visual Studio project/solution files.

From the command line:

msbuild Myproject.sln
查看更多
登录 后发表回答