Click or drag to resize

GeoCoderShortenState Method

Verizon Connect Logo
Print this page
Learn more about Verizon Connect GeoBase.
Get information about the latest release
Convert a given state to its two-letter abbreviation. Given "Texas" ShortenState will return "TX".

Namespace:  Telogis.GeoBase
Assembly:  geobase.net (in geobase.net.dll) Version: 4.99.0.0
Syntax
public static string ShortenState(
	string state,
	Country country
)

Parameters

state
Type: SystemString
Name of a state.
country
Type: Telogis.GeoBaseCountry
See Country.

Return Value

Type: String
Two-letter abbreviation for state
Remarks
Capitalization of the state's full name is ignored. The abbreviation is always returned. as upper-case.
Examples
C#
string shortState = GeoCoder.ShortenState("North Carolina", Country.USA);
// shortenState = "NC"
See Also