Change caption and even procedure of button afer clicking it

adambedford

Registered User.
Local time
Today, 19:28
Joined
Apr 15, 2009
Messages
42
Hi,

I have this code:

Code:
DoCmd.SelectObject acTable, , True
DoCmd.RunCommand acCmdWindowHide

Code:
DoCmd.SelectObject acTable, , True
DoCmd.SelectObject acForm, Me.Name

to show and hide the Access database window/navigation pane...

Is there a way to incorporate both pieces of code into one button. i.e. initially the caption reads "Hide Navigation Window", but after clicking it, it reads "Show Navigation Window".

Thanks!
 

Users who are viewing this thread

Back
Top Bottom