Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All
Expand Minimize

PublicKeyFile Property

Visual Studio .NET 2003

Specifies the file containing the strong name public key. Exposes the functionality of the /publickey option.

[Visual Basic .NET]
Public Property PublicKeyFile() As String
[Visual Basic 6]
Property Get PublicKeyFile() As String
Property Let PublicKeyFile( _
   ByVal NewValue As String _
HRESULT __stdcall get_PublicKeyFile(
   /* [out, retval] */ BSTR* retVal
HRESULT __stdcall put_PublicKeyFile(
   /* [in] */ BSTR NewValue
public string PublicKeyFile {get; set;}
[JScript .NET]
public function get PublicKeyFile() : String
public function set PublicKeyFile(
   NewValue : String


The file containing a strong name public key.

Return Value

A string specifying the file containing the strong name public key.


The value of this property will be blank unless you have secured your application.


' Add a reference to Microsoft.VisualStudio.VCProjectEngine and have a 
' Visual C++ .NET project loaded before running this example.
Imports EnvDTE
Imports Microsoft.VisualStudio.VCProjectEngine
Public Module Module1
Sub Test()
        Dim prj As VCProject
        Dim cfgs, tools As IVCCollection
        Dim cfg As VCConfiguration
        Dim tool As VCAuxiliaryManagedWrapperGeneratorTool
        prj = DTE.Solution.Projects.Item(1).Object
        cfgs = prj.Configurations
        cfg = cfgs.Item(1)
        tool = cfg.Tools("VCAuxiliaryManagedWrapperGeneratorTool")
        MsgBox("Public key file: " & tool.PublicKeyFile)
    End Sub
End Module

See Samples for Project Model Extensibility for information on how to compile and run this sample.

See Also

Applies To: VCAuxiliaryManagedWrapperGeneratorTool Object | VCManagedWrapperGeneratorTool Object

© 2015 Microsoft