Public Function TODMS(n As Double)
Dim A As Double, B As Double, C As Double
A = Int(n)
B = Int(100 * (n - Int(n)) * 0.6) / 100
C = (100 * (n - Int(n)) * 0.6 - Int(100 * (n - Int(n)) * 0.6)) * 0.006
TODMS = A + B + C
End Function 自定义函数 将度分秒转为十进制,在60-90的10分或11分整时结果出错,如输入60.11得结果60.1833333,而不是正确结果60.1666666666请高手指点