Improve company productivity with a Business Account.Sign Up

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 585
  • Last Modified:

Access - Object is Locked message

I recently started getting this message from MS Access 97, whenever a particular form appears:

"The object is locked, so any changes you make will be discarded when the form is closed.  Click Save As/Export on the File menu and save the object under a different name."

What is the meaning of this message and how does this issue usually get resolved?

It never appeared until after the mdb file was converted to mde.
0
jwilk8284
Asked:
jwilk8284
  • 5
  • 4
1 Solution
 
MacRenaCommented:
jwilk8284,

Please open the .mdb and set the Form's RecordLocks property to "No Locks".  Then recompile it to the .mde and see if that fixes it.

If that doesn't fix it, please tell me what controls and other objects exist on the Form (excluding labels).

What I'm looking for here is if you can determine the "object" that Access is reporting is locked.

Mac

0
 
jwilk8284Author Commented:
MacRena,

The RecordLocks property is set to "No Locks".

There are several locked fields on this form.  The intention is to allow the user to view the information but not make any changes.

One field has "Data Entry" = No.

There are some command buttons - all of them activate different macros when clicked.

I originally believed this was a problem with the conversion to .mde type of file.  Probably not.  I observed it happening on an .mdb type of file.  
0
 
MacRenaCommented:
jwilk8284,

I have some programs with "Locked" textboxes that show data but won't accept changes.  That does not cause the message you are describing.

Just so we aren't chasing our tails, do a repair on the data database.

When you say
>>"One field has "Data Entry" = No"<<
Could you possibly mean a FORM has that setting?  As far as I know, textboxes and other "field" controls are not capable of that.  

But that only determines if the FORM  will shown all of the records (Data Entry = No) or just the new one (Data Entry = Yes).

Is the FORM that gives the message set differently than other FORMS?

What Security do you have on the Database?  Are any FORMS protected in any way?

I confess I don't remember ever seeing this message in this situation, so I am hoping to fix it by hit-or-miss.  That means, if the repair doesn't fix it, you will have to compare this FORM with other FORMS to see differences.

We'll keep at it.

Mac

0
Get 10% Off Your First Squarespace Website

Ready to showcase your work, publish content or promote your business online? With Squarespace’s award-winning templates and 24/7 customer service, getting started is simple. Head to Squarespace.com and use offer code ‘EXPERTS’ to get 10% off your first purchase.

 
MacRenaCommented:
jwilk8284,

Any Pictures or other interesting controls on the FORM?

Mac
0
 
jwilk8284Author Commented:
MacRena,

The RecordLocks property is set to "No Locks".

There are several locked fields on this form.  The intention is to allow the user to view the information but not make any changes.

One field has "Data Entry" = No.

There are some command buttons - all of them activate different macros when clicked.

I originally believed this was a problem with the conversion to .mde type of file.  Probably not.  I observed it happening on an .mdb type of file.  
0
 
MacRenaCommented:
jwilk8284,

Did you respond?

I don't understand how your previous Comment was reproduced here 4 1/2 hours later after I posted 2 Comments.

Mac
0
 
jwilk8284Author Commented:
MacRena,

Sorry about the 4/11/2000 11:20 am comment - my previous comment was re-posted by mistake.

I will try a database repair and let you know (tonight or tomorrow).

I stand corrected "Data Entry" = No" applies to the form.  As I understand it, this means that only existing records can be displayed.

Will get back to you after trying to repair the database.


0
 
jwilk8284Author Commented:
MacRena,

I tried a database repair and did not have any problem after that. Apparently that takes care of the problem.  Thank you.  100 points.

0
 
MacRenaCommented:
jwilk8284,

Great!  Glad it worked!

One additional remark - "Data Entry = No" will show all records, including a NEW record (one CAN be created here) but "Data Entry = Yes" will ONLY show the NEW record.  You can not show existing records when set to Yes.  I have had to write code to prevent adding new records to a form.  If you find a way to get "Only Existing Records" to show in a Property setting, please tell me about it. :?)

Mac
0
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.

Join & Write a Comment

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

  • 5
  • 4
Tackle projects and never again get stuck behind a technical roadblock.
Join Now