Results 1 to 3 of 3
  1. #1
    Lounger
    Join Date
    Nov 2006
    Posts
    29
    Thanks
    0
    Thanked 0 Times in 0 Posts

    refreshing form data (access 2003)

    I am having a problem with refreshing data on the form - no query involved - just math functions.
    I created "refresh' button by using 2003 wizard, but I am getting "the command or action 'refresh' isn't available now"
    any idea?
    thank you
    Alex

  2. #2
    Super Moderator
    Join Date
    Jun 2002
    Location
    Mt Macedon, Victoria, Australia
    Posts
    3,993
    Thanks
    1
    Thanked 45 Times in 44 Posts

    Re: refreshing form data (access 2003)

    The Wizard writes archaic code for me.refresh.

    Here is what Help says about Refresh:
    The Refresh method and Refresh command show changes you or other users have made to the underlying record source for any of the currently displayed records in forms and datasheets. The Repaint method simply updates the screen when repainting has been delayed while Microsoft Access completes other tasks.

    So if you form is not bound to any underlying records it can't be refreshed.

    Are you trying to force the screen to be updated?, or for some calculations to be performed again?

    You could try me.repaint or me.recalc
    Regards
    John



  3. #3
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: refreshing form data (access 2003)

    To update calculations, use

    Me.Recalc

    in the On Click code of the button.

Posting Permissions

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