private static LatLongDecimal ConvertDegMinSecToDecimal(LatLongDegMinSec InData)
{
LatLongDecimal OutData = new LatLongDecimal();
const double OneOverSixty = 1.0 / 60.0;
OutData.LatitudeDecimal = InData.Latitude.Deg + (InData.Latitude.Min * OneOverSixty) + (InData.Latitude.Sec * OneOverSixty * OneOverSixty);
OutData.LongitudeDecimal = InData.Longitude.Deg + (InData.Longitude.Min * OneOverSixty) + (InData.Longitude.Sec * OneOverSixty * OneOverSixty);
if (InData.Latitude.Prefix == LatLongPrefix.S)
OutData.LatitudeDecimal = OutData.LatitudeDecimal * -1.0;
if (InData.Longitude.Prefix == LatLongPrefix.W)
OutData.LongitudeDecimal = OutData.LongitudeDecimal * -1.0;
return OutData;
}