Specifies a file containing a key or key pair to give an assembly a strong name.
/keyfile:file
-or-
/keyfile:"file"
The compiler inserts the public key into the assembly manifest and then signs the final assembly with the private key. To generate a key file, type sn -k file at the command line.
If you compile with /target:module, information about the key file is held in the module and incorporated into the assembly that is created when you compile an application with /reference.
You can also pass your encryption information to the compiler with /keycontainer. Use /delaysign if you want a partially signed assembly.
See
This option is not available within the development environment.
To set /keyfile programmatically
The following code compiles source file input.vb
and specifies a key file:
vbc /keyfile:myfile.sn input.vb