Access apd will not allow forms to be deleted or renamed

I've developed an Access .adp application (Access 2010/SQL 2008R2) which works fine - but if I try to rename a form or delete a form the sub menu that opens when you right click on the form has the Delete and Rename option greyed out.

I created a blank database and imported all the forms/reports/macros/modules successfully from the Access.adp front end database and connected the front end database to the back end SQL database but sill no joy with being able to rename/delete forms.

I have opened all tables/ forms - just to make sure there was no problems - everything opened as expected and I even recompiled the front end database - still no joy.

I have several other Access.adp databases running in the same PC/Server and all allow me to rename/delete forms/reports etc.

Is there some system setting that I should set on/off?

Many thank for you assistance
Who is Participating?
BitsqueezerConnect With a Mentor Commented:
Hi Michael,

as Scott said, the DAO library was exchanged beginning with A2007, because the database engine was exchanged from JET to ACE. But if you do not explicitly need DAO for any reason in your frontend you can completely remove it as an ADP normally don't need DAO, only ADO (which also should be version 6.x depending on the target Windows version you want to use - beginning with Windows Vista it should be 6.x, in case of Windows XP it should be version 2.8, and the frontend should only compiled on a Windows XP machine then as the 2.8 from >=Vista is not compatible with the 2.8 from XP).

As you can also use ADO to open an ACCDB/MDB (if you want to do that in your ADP frontend) you should rewrite DAO code to ADO code in your frontend and remove the DAO reference completely from your frontend.


Scott McDaniel (Microsoft Access MVP - EE MVE )Connect With a Mentor Infotrakker SoftwareCommented:
Try to Decompile the application. To do that, create a Shortcut with this as the Target:

"full path to msaccess.exe" "full path to your db" /decompile

Do that, then Compact the database. Next, open the VBA Editor and Click Debug-Compile. Fix any errors, and continue doing that until the menu item is disabled. Now compact again.
BitsqueezerConnect With a Mentor Commented:

I made a module which exports any object in an ADP into a new ADP including the Access properties and VBA references. It uses Application.LoadFromText and Application.SaveAsText to export and import which makes sure that the result are decompiled text objects so any "binary trash" is removed in the new database file. I use that from time to time to refresh my ADPs during development and helped me often.

The module can be found here:


AdlermAuthor Commented:
Hi Scott / Christian

Scott I tried you suggestion but it did not fix my problem.
Christian I' still to test you approach.

As a background note I should have said the frontend Access.adp database that I'm having trouble with was originally developed under Access 2007 and transported across to Access 2010.  The other Access.adp applications I referred to were developed only under Access 2010.

To bring you up to date I think I have identified the cause but I don't know why it is causing it.

I created a new frontend Access.adp (2010) database linked to the backend SQL Server database and then imported all the object groups (forms/reports/macro/modules - in that order) from the old frontend database.

I checked the form's submenu after importing each object group, closed the application and then reopened it again checking the forms submenu. Rename/Delete options on the form's submenu were active on all occasions, however, after importing the Modules object group, closing the application and the reopening it I started to get compile error messages.

I then started to check various references (e.g. Visual Basic For Applications, Microsoft Access 14.0 Object Library etc.). Again everything was OK - with respect to the forms' submenu Rename/Delete options - until I checked the Microsoft DAO 3.6 Object Library.

After checking the Microsoft DAO 3.6 Object Library reference I recompiled the program (this got rid of the compile error I was encountering ) checked the forms' submenu (Rename/Delete options still active) and closed the application.

Unfortunately on reopening the application - at this stage - The form's submenu Rename/Delete options were no longer active (greyed out).

I carried out a number of other tests - to verify if the Microsoft DAO 3.6 Object Library reference was the culprit - by removing it from the reference list and then adding it back into the reference list. Each time the reference was removed from the reference list the form's submenu Rename/Delete options were active after reopening the application. Conversely, the form's submenu Rename/Delete options were not active if the Microsoft DAO 3.6 Object Library reference was included in the reference list.

Hope this may shed some light on the problem.

Many thank for your assistance

Michael Adler
Scott McDaniel (Microsoft Access MVP - EE MVE )Infotrakker SoftwareCommented:
DAO 3.6 generally is not used with 2007 and above. Instead, you use the "Office xx Access Database Engine Object Library", as you've indicated.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.