Overview
Program Location
Usage
Brackets indicate optional parameters. Don’t include [ ] around arguments.
Command Line Reference
- Help (displays command line parameters)
- Input (vb code to convert)
- Conversion options
- Output (where to place C# output files)
Help
- /? – This will display command line parameters. If specified, all other parameters will be ignored.
Input
- Path\filename.vb – individual .vb files to convert (wildcards may be used)
- Path\filename.vbproj – VB.Net project to convert (wildcards may be used)
- Path\filename.sln – solution to convert (wildcards may be used)
- /S – search subdirectories if wildcard is specified in path names above
- /G: groupName – convert project group.
- /L:”vb line” - convert individual line of code (C# output to stdout)
Conversion Options
- /V:2003|2005|2008|2010|2012|2013|2014 – VB.Net version to use when converting. Default is highest supported by computer for .vb files and single line conversions, and auto-detect for project conversions.
- /P:integer – number of parallel processes to use when converting multiple projects. Default is parallelism specified in program options screen.
Output
- -O:outputDirectory – Used for .vb file conversions only, not projects, solutions, or groups, which use the target directory options in program options screen.
Examples
Example 1
vbtocscmd.exe d:\code\test.vbproj
Example 2
vbtocscmd.exe d:\code\*.vbproj /S /P:8
Example 3
vbtocscmd.exe d:\code\*.vb
Example 4
vbtocscmd.exe d:\code\test.vb /O:”d:\code\cs”