Important This document may not represent best practices for current development, links to downloads and other resources may no longer be valid. Current recommended version can be found here. ArchiveDisclaimer


Specifies the location of Mscorlib.dll and Microsoft.VisualBasic.dll.



The directory containing the versions of Mscorlib.dll and Microsoft.VisualBasic.dll to use for compilation. This path is not verified until it is loaded. Enclose the directory name in quotation marks (" ") if it contains a space.

This option tells the Visual Basic compiler to load the Mscorlib.dll and Microsoft.VisualBasic.dll files from a non-default location. The /sdkpath option was designed to be used with /netcf. The .NET Compact Framework uses different versions of these support libraries to avoid the use of types and language features not found on the devices.


The /sdkpath option is not available from within the Visual Studio development environment; it is available only when compiling from the command line. The /sdkpath option is set when a Visual Basic device project is loaded.

The following code compiles Myfile.vb with the .NET Compact Framework, using the versions of Mscorlib.dll and Microsoft.VisualBasic.dll found in the default installation directory of the .NET Compact Framework on the C drive. Typically, you would use the most recent version of the .NET Compact Framework.

vbc /netcf /sdkpath:"c:\Program Files\Microsoft Visual Studio .NET 2003\CompactFrameworkSDK\v1.0.5000\Windows CE " myfile.vb
© 2015 Microsoft