LoadCultureDropDownList loads a DropDownList with the list of supported cultures based on the languages defined in the supported locales file

This overload allows us to filter a language from the dropdown. To do so pass a language code to the Filter parameter

This overload allows us to display all installed languages. To do so, pass the value True to the Host parameter

Namespace: DotNetNuke.Services.Localization
Assembly: DotNetNuke (in DotNetNuke.dll)

Syntax

C#
public static IEnumerable<ListItem> LoadCultureInListItems(
	CultureDropDownTypes displayType,
	string selectedValue,
	string filter,
	bool host
)
Visual Basic
Public Shared Function LoadCultureInListItems ( 
	displayType As CultureDropDownTypes,
	selectedValue As String,
	filter As String,
	host As Boolean
) As IEnumerable(Of ListItem)

Parameters

displayType
Type: DotNetNuke.Services.Localization..::..CultureDropDownTypes
paramdisplayTypeM:DotNetNuke.Services.Localization.Localization.LoadCultureInListItems(DotNetNuke.Services.Localization.CultureDropDownTypes,System.String,System.String,System.Boolean)
selectedValue
Type: System..::..String
paramselectedValueM:DotNetNuke.Services.Localization.Localization.LoadCultureInListItems(DotNetNuke.Services.Localization.CultureDropDownTypes,System.String,System.String,System.Boolean)
filter
Type: System..::..String
paramfilterM:DotNetNuke.Services.Localization.Localization.LoadCultureInListItems(DotNetNuke.Services.Localization.CultureDropDownTypes,System.String,System.String,System.Boolean)
host
Type: System..::..Boolean
paramhostM:DotNetNuke.Services.Localization.Localization.LoadCultureInListItems(DotNetNuke.Services.Localization.CultureDropDownTypes,System.String,System.String,System.Boolean)

Return Value

returnsM:DotNetNuke.Services.Localization.Localization.LoadCultureInListItems(DotNetNuke.Services.Localization.CultureDropDownTypes,System.String,System.String,System.Boolean)

See Also