Form becomes data entry onyl

stepone

Registered User.
Local time
Today, 18:46
Joined
Mar 2, 2004
Messages
97
Hello,

Has anyone come across this problem.

I have a database where I use a single form (frmPatientDetails) both to Enter new patients and also to View the details for existing patients.

I use DoCmd.openform frmPatientDetails, , , , acFormAdd to open the form in data entry mode. When viewing exsting records I use simply DoCmd.openform frmPatientDetails

3 users use the database regularly (they each have their own copy). One of them has twice reported a problem that when trying to view patient details, the form opens with all fields blank. It turns out (when I get a chance to look at it) that the forms DataEntry property is set to Yes. I don't set this property anywhere in the code, and it is set to No in all other copies of the database.

My question is - can this behaviour be caused by opening the form using acFormAdd. When opening the form to view details, should I explicitly state acFormEdit, or is it good enough to assume default behaviour.

Thanks for any pointers,
StepOne
 
try with this

put these on open form event:

Me.AllowAdditions = False '(yor cant make new data)
Me.AllowDeletions = False '(you cant delete records)
Me.AllowEdits = False '(you cant make changes)

this is usefull only for viewing

in other hand:
Me.AllowAdditions = True (can make new data)

and so on...
 

Users who are viewing this thread

Back
Top Bottom