In VBA it looks like it rounds. If I have the function
Function myint(x As Double) As Integer
myint = x
End Function
then myint(3.9) yields 4 instead of the value of 3 that I was expecting.
I can't find a place in the documentation where this is documented. Can someone point me in the right direction? I'm using Office 2010, and even a pointer to help pages would be a big help. I'd like to see whether there are some other assumptions I'm making that might not hold in VBA.
Thanks
Function myint(x As Double) As Integer
myint = x
End Function
then myint(3.9) yields 4 instead of the value of 3 that I was expecting.
I can't find a place in the documentation where this is documented. Can someone point me in the right direction? I'm using Office 2010, and even a pointer to help pages would be a big help. I'd like to see whether there are some other assumptions I'm making that might not hold in VBA.
Thanks