Importing custom toolbars and import/export specifications

M

Michael Scott

I need to make an exact copy of a database from within my code.

I know I can use the TransferDatabase method to import objects but
there seems to be no way of importing menus, toolbars and import/
export specifications.

When you manually import a report using File/Get External Data/Import,
there are checkboxes in the Options to include menus, toolbars and
import/export specifications.

How do I achieve the equivalent of checking those boxes using the
DoCmd.TransferDatabase command in VBA? Or do I have to do it some
other way?
 
J

Jeff Boyce

Michael

Why? As in "what business need are you attempting to solve by making an
exact duplicate?"

I'm not asking out of prurient interest, but because the newsgroup readers
may be able to offer alternate approaches, if we knew what the problem being
solved was...

Regards

Jeff Boyce
Microsoft Office/Access MVP
 
M

Michael Scott

Why? As in "what business need are you attempting to solve by making an
exact duplicate?"

Thanks for the quick reply.

I'm attempting to secure a database by using DAO to program workgroup
security rather than using the security wizard.

I (think I) understand workgroups, users and permissions, and
understand how to set permissions on database objects. I can also
change the ownership of objects within the target database. What I am
stuck on is changing the ownership of the database itself. As I
understand it, the only way of achieving this (and this, I think, is
what the security wizard does) is to export copies of all the objects
from the original database into a new database, which becomes the
secured database. I was thinking along the lines of using
TransferDatabase to achieve this, but don't know how to also export
menus, toolbars and import/export specifications by that method.

Do I need to do this, or is it overkill? The steps I have taken so far
are:

1. Create new administrator user and add it to the Admins group.
2. Remove Admin user from Admins group.
3. Remove all specific permissions assigned to the Admin user and the
Users group.
4. Change the ownership of all database objects to the new
administrator user.

Is it also really necessary to change the ownership of the database,
or will the above steps be sufficient? I have to admit that I have
found workgroup security a bit of a struggle to get to grips with, and
still sometimes get confused by what I am trying to achieve, so any
advice would be very welcome. My guidance so far has all come from the
excellent "Microsoft Jet Database Engine Programmer's Guide".

Many thanks in advance.

Michael
 
J

Jeff Boyce

Michael

Given the topic & direction, I think you find a lot more folks with
experience over in the "security" newsgroup.

I know you've just passed me in the deep end!

Good luck

Regards

Jeff Boyce
Microsoft Office/Access MVP
 
M

Michael Scott

Michael
Given the topic & direction, I think you find a lot more folks with
experience over in the "security" newsgroup.

I know you've just passed me in the deep end!

Good luck

Regards

Jeff Boyce
Microsoft Office/Access MVP

I came to the same conclusion. :)

Thanks.
 

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