I am trying to use an example to write my first function. Iv'e copied it from an old version of Access/VB (Access 97). Function FirstOfNextMonth().
I create a new module, type this in and assign the results of the calculation = DateSerial(Year(Now), Month(Now) +1,1. End Function. I try to comile it but the only option is to compile whole Database. No error message ocurs, so I save it as FirstOfNextMonth(). I try to add it to a form for adding members to my database by using a text box and seet the control to this function but when I view my form I get #Name error. What am I doing wrong? I'm using Access 2000.
I create a new module, type this in and assign the results of the calculation = DateSerial(Year(Now), Month(Now) +1,1. End Function. I try to comile it but the only option is to compile whole Database. No error message ocurs, so I save it as FirstOfNextMonth(). I try to add it to a form for adding members to my database by using a text box and seet the control to this function but when I view my form I get #Name error. What am I doing wrong? I'm using Access 2000.