Checks if the provided degrees part of a longitude in DMS is valid
true - if the degrees part is valid, false - if the degrees part is invalid
The function verifies validity of its arguments and parsing results. The valid degrees part is an integer number in the range from 0 (inclusive) to 180 (exclusive).
This sample shows how to call the Geodetic.Longitude.IsValidDegrees method from C# code:
string errorMessage = String.Empty;
int degrees = 34;
string str = String.Empty;
if (Geodetic.Longitude.IsValidDegrees(degrees, out errorMessage))
{
Console.WriteLine("The degrees part is valid.");
}
else
{
Console.WriteLine(errorMessage);
}