问题
In my previous question heading as bellow:
"How to avoid Linked Table manager message while opening the Access DB."
I have asked how to disable Macro (programmatically vb.net) while opening the MSAccess DB and I got some good reference and code samples to do so. But unfortunately I could not able to achieve the expected result. I have tried API to enable/disable Keys (SHIFT) at run time and also use some command-line options programmatically but still it’s not working even not getting any error as well.
Problem:
- One of my AccessDB contains Macro and it calls a form while opening the DB. And the form has some link to Tables and it creates interrupt asking proper path to the table and halts the application till the user intervention.
- Other one calls form in start-up while opening the DB. It causes opening of all the forms while running the Application.
I need to resolve both the problem and run the application smoothly.
Please anyone there to help me someway....
Thank you.
回答1:
See By Pass Shift Key Code
This code simply lets you browse to a mdb database of your choice, and enable, or disable the shift key during the startup of the mdb/mde.
Down a ways on the following page: http://www.members.shaw.ca/AlbertKallal/msaccess/msaccess.html
回答2:
On one of the MS support pages I found a reference to the /nostartup switch. Can you try to add that to your startup command?
来源:https://stackoverflow.com/questions/684774/how-to-disable-macro-and-start-up-values-while-opening-the-ms-access-db