Walter.BOM
GetInternationalCountryName(Nullable<GeoLocation>,CultureInfo) Method
Walter.BOM Assembly > Walter.BOM.Geo Namespace > GeoExtensionMethods Class > GetInternationalCountryName Method : GetInternationalCountryName(Nullable<GeoLocation>,CultureInfo) Method
The geographic location for which to obtain the localized country name. Can be null, in which case a default or fallback name may be returned.
The System.Globalization.CultureInfo object representing the culture according to which the country name should be localized. Cannot be null.
Retrieves the name of the country associated with the specified GeoLocation value, localized according to the provided System.Globalization.CultureInfo.
Syntax
public static string GetInternationalCountryName( 
   Nullable<GeoLocation> location,
   CultureInfo culture
)

Parameters

location
The geographic location for which to obtain the localized country name. Can be null, in which case a default or fallback name may be returned.
culture
The System.Globalization.CultureInfo object representing the culture according to which the country name should be localized. Cannot be null.

Return Value

A string containing the country name localized to the language and cultural norms of the specified culture. If the location is null or does not correspond to a recognized country, or if localization for the specified culture is not available, a default or English name may be returned, depending on implementation.
Exceptions
ExceptionDescription
Thrown when the culture argument is null, indicating that a valid System.Globalization.CultureInfo object is required for the operation.
Remarks
This method is essential for applications targeting a global audience, enabling the display of country names in a manner that is culturally and linguistically appropriate for users based on their specified preferences. It requires that the application has access to localized resources or a mapping of GeoLocation values to country names in multiple languages.
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

GeoExtensionMethods Class
GeoExtensionMethods Members
Overload List