Prattdakota
Vendor
I have a form which has a command button on it. The On Click event of the button invokes the class object form code which uses the Month function as follows:
When run, the code produces a type mismatch error. If I run this same code in a module it works fine and x turns out to be 10. If someone could enlighten me as to the reason the function doesn't work in a class object I would be grateful.
Thanks
Code:
Dim x As Integer
x = Month(#10/5/2004#)
When run, the code produces a type mismatch error. If I run this same code in a module it works fine and x turns out to be 10. If someone could enlighten me as to the reason the function doesn't work in a class object I would be grateful.
Thanks