Server.Languages Server.Languages Server.Languages Property

Definition

Represents a collection of Language objects. Each Language object represents an languages supported by the instance of SQL Server.

public:
 property Microsoft::SqlServer::Management::Smo::LanguageCollection ^ Languages { Microsoft::SqlServer::Management::Smo::LanguageCollection ^ get(); };
[Microsoft.SqlServer.Management.Sdk.Sfc.Metadata.SfcObject(Microsoft.SqlServer.Management.Sdk.Sfc.Metadata.SfcContainerRelationship.ObjectContainer, Microsoft.SqlServer.Management.Sdk.Sfc.Metadata.SfcContainerCardinality.ZeroToAny, typeof(Microsoft.SqlServer.Management.Smo.Language))]
public Microsoft.SqlServer.Management.Smo.LanguageCollection Languages { get; }
Public ReadOnly Property Languages As LanguageCollection
Property Value

A LanguageCollection object that represents all the languages supported by the instance of SQL Server.

Examples

Visual Basic

'Connect to the local, default instance of SQL Server.  
Dim srv As Server  
srv = New Server  
'Display the supported languages.  
Dim lng As Language  
For Each lng In srv.Languages  
    Console.WriteLine(lng.Name)  
Next  

PowerShell

$srv = new-object Microsoft.SqlServer.Management.Smo.Server("(local)")  
foreach ($lng in $srv.Languages)  
{  
   Write-Host $lng.Name  
}  

Remarks

The Languages property points to the LanguageCollection object. You can use the collection to reference the various written languages that are supported by SQL Server.

Applies to