Walter.BOM
ToDmsLongitude(Decimal) Method
Example 
Walter.BOM Assembly > Walter.BOM.Geo Namespace > LocationExtensionMethods Class > ToDmsLongitude Method : ToDmsLongitude(Decimal) Method
The longitude value to convert. Positive values indicate east longitude and negative values indicate west longitude.
Converts a decimal longitude value to a string representation in degrees, minutes, and seconds (DMS) format with a cardinal direction (E or W).
Syntax
public static string ToDmsLongitude( 
   decimal longitude
)

Parameters

longitude
The longitude value to convert. Positive values indicate east longitude and negative values indicate west longitude.

Return Value

A string representing the longitude in DMS format. For example, "2°10'26.5\"E" for a longitude of 2.17403.
Example
decimal longitude = 2.17403m;
string dmsLongitude = longitude.ToDmsLongitude();
Console.WriteLine(dmsLongitude); // Output: 2°10'26.5"E
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

LocationExtensionMethods Class
LocationExtensionMethods Members
Overload List