Results 1 to 3 of 3
  1. #1
    Join Date
    Jan 2002
    Location
    Vancouver
    Posts
    7

    Unanswered: Wierd problem - please help

    I have a wierd problem with Access 2000. In the AfterUpdate event of any of the bound or unbound textboxes on my subform, I keep getting the following message, even if the only code is: Dim x as Integer

    The expression AfterUpdate you entered as the event property setting produced the following error: Variable not defined. *The expression may not result in the name of a macro, the name of a user-defined function or [Event Procedure]. *There may have been an error evaluating the function, event or macro.

    It also happens in the BeforeUpdate event, but not on the Change event. I'm sure it means something else entirely, but what?

    Has anyone run into this before?

  2. #2
    Join Date
    Jan 2002
    Location
    At the Edge of America!
    Posts
    55
    I have. I had to recreate the form. You should try starting your form from scratch. If not that then copy your form and delete all of the code. Add each piece one by one until you recreate the error.

  3. #3
    Join Date
    Jan 2002
    Location
    Vancouver
    Posts
    7

    Smile

    Thanks for the good advice I deleted all my code and put it back line by line and discovered my subform was referring to a variable of the parent form. By making it a Global variable in a module, the "weird error" went away. Actually, now that I know the problem, it was not so weird, it was just a msgbox that did not give the usual options to debug or end.

    Thanks again.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •