How to open a secured Access db from Excel

  • Thread starter Thread starter erick-flores
  • Start date Start date
E

erick-flores

Hello guys

I have been trying to find a solution for this problem in the last 3
days.

I have a secured Access database. This db contains a Macro that i will
like to run from Excel. I need the code to run the Macro from Excel.
Any ideas?

Thanks in advance
 
Thanks for ur reply. But remenber I have a 'secured database'

I tried:
Private Sub Cmd_refresh_Click()
Shell ("C:\Program Files\Office97\Office\MSACCESS.EXE /excl /
NOSTARTUP /wrkgrp path_to_security.MDW path_to_database.mdb")
chan = DDEInitiate("MSACCESS", "system")
application.DDETerminate chan

And it looks like the Shell does not recognized with the .mdw option
on it. Any ideas how I can add the security file to the shell?
 
You might get more help in the Access newsgroup. Sorry.

microsoft.­public.­access.­modulesdaovba
microsoft.­public.­access.­externaldata

ps- why are you using Shell to automate MS Access? You could
instantiate it directly from Excel (by setting a reference to the
Access object library) and then manipulate Access objects from Excel.

--JP
 
You might get more help in the Access newsgroup. Sorry.

microsoft.­public.­access.­modulesdaovba
microsoft.­public.­access.­externaldata

ps-  why are you using Shell to automate MS Access? You could
instantiate it directly from Excel (by setting a reference to the
Access object library) and then manipulate Access objects from Excel.

--JP

Well...I tried to used the link that you gave me, which references in
using Shell. I have tried using the Access object libraries but I cant
get it to work. My problem is that the database is secured, when I use
my code against a non-secured database everything works fine.

Thanks anyways.
 
Maybe this helps?

I forgot to mentioned that my database has user-level security. I have
already looked at the link you gave me, but that one works with
secured database. If you read number 3 under the Summary section it
says:
"Open the database. Note that opening a secured Access database is
different from opening a database that is secured with the Microsoft
Access user-level security feature."
So this will not work for me. Sorry for my lack of information.

Anyways thanks for ur replies, if you still have any more links out
there please let me know...I am going crazy trying to figured this one
out.
 
Sorry, my lack of familiarity with Access is showing. Again you might
want to post your query in the Access ngs:

microsoft.­public.­access.­modulesdaovba
microsoft.­public.­access.­externaldata


--JP
 
Back
Top