Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

VBPROJ / CSPROJ

I'm trying to dig into the XML for a VBPROJ file. Does anyone know where I can find a good resource that explains the structure and attribute usage?

like image 837
Danny G Avatar asked Mar 26 '09 18:03

Danny G


People also ask

What is Csproj file used for?

csproj file to determine the packages to install from Nuget. To compile an ASP.NET application, the compiler needs information such as the version of the dotnet framework, the type of the application, etc. A . csproj file stores all this information that allows dotnet to build and compile the project.

What kind of file is Csproj?

What is a CSProj file? Files with CSPROJ extension represent a C# project file that contains the list of files included in a project along with the references to system assemblies. When a new project is initiated in Microsoft VIiual Studio, you get one .

Does order matter in Csproj?

Yes, you can just merge it. The order makes no difference.


3 Answers

csproj or vbproj files are nothing but msbuild xml files, which would be consumed by msbuild.exe. These xml files adhere to msbuild schema namely: Microsoft.Build.xsd.

  1. see http://msdn.microsoft.com/en-us/library/5dy88c2e.aspx for msbuild schema reference.
  2. Read Sara Ford's blog post about editing csproj/vbproj files in VS IDE
  3. Where is the MSBuild schema file?
  4. Another post on msdn blogs about editing csproj/vbproj files
like image 121
abhilash Avatar answered Nov 02 '22 16:11

abhilash


If you're looking for this info in order to programatically rip through some vbproj files, you'll probably want to take a look at Microsoft.Build.Engine.dll. Referencing this component gives you access to the MSBuild object model, which can be used to read and manipulate MSBuild files (which csproj and vbproj files are).

like image 28
Craig Vermeer Avatar answered Nov 02 '22 16:11

Craig Vermeer


Take a look at this code. It contains a simple parser for VS solutions and csproj files. Vbproj shouldn't be much different, so you should be able to extend it for your needs. It's licensed under the MIT license.

like image 38
Igor Brejc Avatar answered Nov 02 '22 17:11

Igor Brejc