VB Migration Partner generates .NET projects with a set of “reasonable” options. For example, the output path of generated projects defaults to “bin\Debug\” and “bin\Release”, respectively in Debug and Release mode, and generate the XML documentation file. There is no specific pragma to directly modify these settings, however you can easily use one or more PostProcess pragmas to manipulate the .vbproj file.
For example, say that you want to disable the generation of XML documentation file for a specific project. All you need to do is adding the following pragma somewhere in your source code:
Notice that the last argument is True, to ensure that the pragma is applied to source files other than *.vb or *.cs files. (In this specific case the pragma affects the .vbproj or .csproj file.)
By default, the .NET project generates the *.pdb file in Release mode. You can prevent this from happening by means of the following pragma:
Changing the output path for compiled programs is also simple, if you are familiar with regular expressions. Let’s say that you want to generate all executables in Debug mode in the folder c:\myexes\debug and all executable in Release mode in the folder c:\myexes\release. Here’s the pragma that does the trick:
Notice that you have to double the backslash characters both in the first and in the second argument.
If you want to easily use these pragmas in multiple projects, store them in a VBMigrationPartner.pragmas file and copy the file to the folders where these projects resides.