Sdílet prostřednictvím


Reference.Culture Property

Definition

Gets the culture string of a reference. Read-only.

public:
 property System::String ^ Culture { System::String ^ get(); };
public:
 property Platform::String ^ Culture { Platform::String ^ get(); };
[System.Runtime.InteropServices.DispId(10)]
public string Culture { [System.Runtime.InteropServices.DispId(10)] get; }
[<System.Runtime.InteropServices.DispId(10)>]
[<get: System.Runtime.InteropServices.DispId(10)>]
member this.Culture : string
Public ReadOnly Property Culture As String

Property Value

The return value depends on the reference type.Reference TypeValue ReturnedAssemblyCulture string. For example, "EN-US" for English - United States.COMLocale ID. The string is the hex locale ID of the type library being reference. For example, "0" for multilanguage or "409" for English - United States.

Attributes

Examples

' Macro Editor  
Imports VSLangProj  
Public Sub DisplayCultures()  
   ' The first project is a Visual Basic or C# project.  
   Dim vsProject As VSProject = _  
        CType(DTE.Solution.Projects.Item(1).Object, VSProject)  
   Dim aRef As Reference  

   For Each aref In vsProject.References  
      MsgBox(aRef.Name & " " & aRef.Culture)  
   Next  
End Sub  

Remarks

Culture information includes language and calendar specifications. For information about valid strings, see CultureInfo.

Applies to