Importing custom menus

D

Daniel

Hi,

I've written a procedure that publishes my access-interface to the users by
1)Creating a new .mdb file
2)Copying forms, reports, tables and queries and modules to the new file
3)Changing the settings from developer mode to user mode

This works great but for one thing: I don't know how to transfer my custom
menus to the new .mdb file. I guess I could do it by making a copy of my
current development version, emptying this copy of forms, modules etc. and
exporting my forms, modules etc. to a copy of this template when publishing.
The problem with this approach is that it requires manual intervention each
time I change the menus, or the changes won't propagate to the users.

So, my question is: How do I transfer menus between .mdb files
programmatically?
(You don't have to spell out the code, but some pointers would be nice)

Thanks,

Daniel
 
D

Daniel

There is an option to import menus and toolbars in the standard Import
dialog.
You have to press the [Options] button to see it.

Hi Rick,

I am aware of that, but how do I do it from code? I've been trying to do it
by
copying commandBars and commandBarControls property by property from one
..mdb file to the other, using the CommandBars collection and the Controls
collection of the commandBar object, but it's getting really ugly and I don't
manage to transfer it all properly.

Daniel
 
R

Rick Brandt

Daniel said:
There is an option to import menus and toolbars in the standard
Import dialog. You have to press the [Options] button to see it.

Hi Rick,

I am aware of that, but how do I do it from code? I've been trying to
do it by
copying commandBars and commandBarControls property by property from
one .mdb file to the other, using the CommandBars collection and the
Controls collection of the commandBar object, but it's getting really
ugly and I don't manage to transfer it all properly.

Sorry, I don't know that. I have never had a need to programmatically
import or export a command bar.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top