It must be the heat (it?s currently 105 degrees here today), but I just discovered that I don?t know how to extract the fractional digits from a number like 100.544. Consider the following code:
[vba]Sub DigitsTest
Dim X As Double, Y As Double, Z As Double
X = 100.544 ?This is a constant and not the result of another calculation
Y = Application.RoundDown(X, 0) ?This puts 100 into ?Y?
Z = X ? Y ?This is 100.544 ? 100
Msgbox Z ?This displays 0.543999999999997
End Sub[/vba] Why doesn?t ?Z? contain 0.544 ??
Instead of Y = Application.RoundDown(X, 0) I used Y = Cint(X) , but that rounds up so I get 101 instead of 100.