Results 1 to 8 of 8
  1. #1
    lweis is offline Novice
    Windows 7 64bit Access 2007
    Join Date
    Aug 2019
    Posts
    5

    suddenly unable to make any design changes to more than one forms in my .accdb


    db has been used daily for 2+ years; db has been compacted/repaired; no locks on db; user is admin; can't import or export affected forms to/from a new blank db; can't rename the forms; only errors are attached and occur when I try to import forms into a blank db. All other access object will import except for a handful of forms. Worked with access intermittently or 12+ years and have never seen this
    Attached Thumbnails Attached Thumbnails 1.JPG   2.JPG  

  2. #2
    rpeare is offline VIP
    Windows XP Access 2003
    Join Date
    Jul 2011
    Posts
    5,441
    I have seen this before, at least twice.

    one time I had a duplicate public function declared
    one time I had to re-import all objects into a blank database

    have you got public functions declared in your database?

  3. #3
    lweis is offline Novice
    Windows 7 64bit Access 2007
    Join Date
    Aug 2019
    Posts
    5
    not that I am aware....are you talking about digital certificates?

  4. #4
    lweis is offline Novice
    Windows 7 64bit Access 2007
    Join Date
    Aug 2019
    Posts
    5
    it's not all forms that I can't make design changes to, just a small select number.....these are then the forms that I can't import, export, or rename

  5. #5
    rpeare is offline VIP
    Windows XP Access 2003
    Join Date
    Jul 2011
    Posts
    5,441
    No, I'm not talking about digital certificates.

    If you designed this database you should know though. Any time you do something like click a button to perform an action you have an event (ON CLICK event for example) if you are running vba in any of these events and you have a public function name that conflicts with any other function name you can get this error

    for instance if you had something like


    Code:
    Private Sub cmdButton_Click()
    dim sTest
    
    sTest = getmessage
    
    End sub
    
    Private Function GetMessage()
    GetMessage = "OMG THIS IS MY MESSAGE"
    End Function
    on one of your forms, but then you had a public function

    Code:
    Public Function GetMessage()
    GetMessage = "THIS IS AN ENTIRELY DIFFERENT MESSAGE"
    End Function
    the two functions have the same name which can cause the error you're getting.

    If you did not design the database I would encourage you to go through the code for each object (form, report, module) and search for duplicate function names.

    If that yields no results I would attempt importing the objects 1 at a time into a blank database until you get an error, that might give you the object that has the offending code.

  6. #6
    lweis is offline Novice
    Windows 7 64bit Access 2007
    Join Date
    Aug 2019
    Posts
    5
    I did not design.....I will search code for duplicate function names. Have already tried one-at-a-time import into blank db and I am getting the error on 8 different forms. Thanks for the help

  7. #7
    rpeare is offline VIP
    Windows XP Access 2003
    Join Date
    Jul 2011
    Posts
    5,441
    once you hit a problem form try creating another blank database and importing 1 and only one of those problem objects too. No forms/modules nothing, just the object causing the problem.

  8. #8
    lweis is offline Novice
    Windows 7 64bit Access 2007
    Join Date
    Aug 2019
    Posts
    5
    The name Command2 was showing up repeatedly across the offending forms.....after changing code to a unique name, the form became editable/importable/exportable again. Can't figure out how the name became duplicated across so many forms. It was not designed that way and db has been functioning without fault for years. Thanks again

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Suddenly unable to add new record
    By amg in forum Forms
    Replies: 6
    Last Post: 01-13-2014, 05:38 PM
  2. How do I make my .accdb database 'Read Only'
    By TongaJim in forum Database Design
    Replies: 9
    Last Post: 02-09-2013, 06:18 PM
  3. Replies: 9
    Last Post: 04-20-2012, 08:13 AM
  4. Unable to make ACCDE
    By jhargram in forum Access
    Replies: 5
    Last Post: 04-10-2012, 11:14 PM
  5. Editing forms suddenly gone wrong
    By twinfair in forum Forms
    Replies: 3
    Last Post: 02-19-2010, 07:48 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums