Reputation: 181
In Visual Studio 2008, I am not able to see the Batch Build option for VB.NET projects (as for C++ projects).
I am new to VB.NET, but does it have other options to do a batch build rather than creating a batch file?
Upvotes: 1
Views: 1089
Reputation: 11
Not a very nice solution, but worked on VS 2022, also should work on VS 2008+ as they use msbuild project schema. You'll need manually edit your .vbproj file:
Let say you have project Project.vbproj and you need build 3 release configuration.
Make 4 copies of Project.vbproj: Project_common.vbproj, Project_1.vbproj ... Project_3.vbproj
open Project_common.vbproj in any text (xml) editor and delete all configutation specific element (PropertyGroup, ItemGroup, etc), for example:
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' "> ... ... </PropertyGroup>
<Import Project="Project_common.vbproj" />
Add all 4 into solution, remove old Project.vbproj; in configuration manager exlude Project_common.vbproj from build.
In Project Dependencies make Project_3 depend on Project_2 and Project_2 depend on Project_1 - just for preventing simultaneous build as they may use same files on build.
Now you can build 3 configurations with Build/Rebuild Solution.
It's a not real batch build, you edit *_common project, build *_N projects; not handy for mixed solution; something may go wrong.
You can leave debug configuration in Project_common.vbproj.
Don't forget to backup your project!
Upvotes: 0
Reputation: 7954
There is no such thing as Batch Build for VB.NET projects. Even in mixed solutions with only one Visual Basic project, Batch Build... is disabled/unavailable.
Upvotes: 1
Reputation: 55001
To make the button appear (written from a Visual Studio 2005 perspective, but probably the same or at least very similar for Visual Studio 2008):
Right click on somewhere on the Visual Studio toolbar and select Customize..., then on the Commands tab in the Categories list, select Build.
You should now have a list of Build commands in the Commands list, one of which should be Batch Build.... Drag and drop that to somewhere on the toolbar.
However, I'm not certain if batch builds are supported for Visual Basic, so I'm not sure if this will help you.
Upvotes: 2