X   Site Message
(Message will auto close in 2 seconds)

Welcome to UtterAccess! Please ( Login   or   Register )

Custom Search
   Reply to this topicStart new topic
> Shortcut Menubars, Access 2016    
post Feb 26 2019, 01:40 PM

Posts: 95
Joined: 25-November 18

Just started to create a few shorcut menus for my projects but every time I close the db the form loses the assigned menu and any others in the list.

I'm useing as a start the code from this page Here

I have set a reference to Microsoft Office 16 Object Library

I have clicked the sub name and run them but they don't seem to be saving after db being closed



Go to the top of the page
post Feb 26 2019, 02:19 PM

UtterAccess VIP
Posts: 7,429
Joined: 30-June 11

Might I suggest http://dev-soln.com/access-shortcut-right-click-tool/

Daniel Pineault (2010-2020 Microsoft MVP, UA VIP, EE Distinguished Expert 2018)
Professional Help: https://www.cardaconsultants.com
Free MS Access Code, Tips, Tricks and Samples: https://www.devhut.net

* Design should never say "Look at me". It should always say "Look at this". -- David Craib
* A user interface is like a joke, if you have to explain it, it's not that good! -- Martin LeBlanc

All code samples, demonstration databases, links,... are provided 'AS IS' and are to be used at your own risk! Take the necessary steps to check, validate ...(you are responsible for your choices and actions)
Go to the top of the page
post Feb 27 2019, 01:31 PM

UtterAccess VIP
Posts: 3,123
Joined: 12-April 07
From: Edmonton, Alberta Canada

There is a bit of a "bug" in that code.

They mention that you don't have to re-run the code each time, but the sample code is written that you DO HAVE to run the code each time.

From that example, you want to change the Temporary setting to FALSE (So if set true - the menu/control bar is temp and removed).

So change this:

   Set cmbShot = CommandBars.Add("Test1", msoBarPopup, False, True)

Note the last setting of True. You want this:

   Set cmbShot = CommandBars.Add("Test1", msoBarPopup, False, False)

Albert D. Kallal (Access MVP 2003-2017)
Edmonton, Alberta Canada

Go to the top of the page

Custom Search

RSSSearch   Top   Lo-Fi    3rd August 2020 - 03:36 PM