Share via

How programatically (in VBA code) to select specific NavigationButton in a NavogationForm

Anonymous
2012-04-07T23:26:23+00:00

Hi! 

I am designing an application in Access 2010 ( a desktop version) and am using the new NavigationForm. My Application will have 4 or more steps. In NavigationButton1 I am entering some data and need (want) to continue with Step 2, linked to NavigationButton2 .... So I an trying to find a way to trigger the event of navigationButton2 that opens the form as per Navigation Target Name of the button. In the NavigationForm, NavigationControl or NavigationButton Properties I cannot see any event or Macro that can be included in my NavigationButton1 procedure ...

Microsoft 365 and Office | Access | For home | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

Answer accepted by question author

Anonymous
2012-04-08T00:03:16+00:00

Use the browseto command.

If you browseto a form that is included in the nav buttions, then that one becomes active.

eg:

DoCmd.BrowseTo acBrowseToForm, _

                      "Form3", _

                      "Navigation Form.NavigationSubForm", _

                      "where condition"

Note that if in say a choice of 5 nav buttons, you do NOT have form3 (as in the above example) then the current existing sub form will be replaced. However, if the 4th button is set to form3, then the above would display form 3, and the 4th button would highlight.

And, as the above shows, you can add in a where clause.

The above browse to command of course is available in both VBA as above, or as a macro command.

This navagation feature is for web forms, but is a great choice for desktop also.

Albert D. Kallal (Access MVP)

Edmonton, Alberta Canada

Was this answer helpful?

0 comments No comments

1 additional answer

Sort by: Most helpful
  1. Anonymous
    2012-04-08T07:44:53+00:00

    Thank you! That was really helpful!

    Was this answer helpful?

    0 comments No comments