Delete form from another password protected database (1 Viewer)

Jaye7

Registered User.
Local time
Tomorrow, 02:32
Joined
Aug 19, 2014
Messages
205
I have been searching for a script to delete a form from another password protected database and I have found scripts to delete tables but not forms.
 

Jaye7

Registered User.
Local time
Tomorrow, 02:32
Joined
Aug 19, 2014
Messages
205
I have the following script which works if the database is open, but if it's closed then I need my password.


Code:
Dim objAcc As Access.Application
Set objAcc = GetObject("X:\Test1.mdb")
objAcc.DoCmd.DeleteObject acForm, "frm_Utilities"
 

bob fitz

AWF VIP
Local time
Today, 17:32
Joined
May 23, 2011
Messages
4,728
I have been searching for a script to delete a form from another password protected database and I have found scripts to delete tables but not forms.
Just curious. Why would you want to delete a form with code rather than doing it manually.
 

Jaye7

Registered User.
Local time
Tomorrow, 02:32
Joined
Aug 19, 2014
Messages
205
Because I am going to delete numerous forms from up to a dozen different databases, when you have code you don't have to do things manually, I would have my car drive me to work if I could write code to make it do it.
 

Users who are viewing this thread

Top Bottom