read-only after updates?

B

Brook

hello...

what I am trying to accomplish is this:

I have an orders form that I use to create new orders, and what I would
like to do is that once the form is closed, or a new record is added, the
information is read-only, but with password protected for edits?

any tips?

Brook
 
S

Steve Schapel

Brook,

First of all you can set the Allow Edits property of the form to No.

Then you can put a Command Button on the form, with code on its Click
event something like this...
If InputBox("Enter password") = "fred" Then
Me.AllowEdits = True
End If
 
B

Brook

Thanks for the response,

Would this code allow me to open the form and add a new record, but if I
wanted to edit and existing record I would click the password button.?

Thanks,

Brook
 
B

Brook

Yes I did try it and it works like it is supposed to, but the think is, is
that I don't want to have to enter a password everytime I want to add a new
record, just when I want to edit a record.

So I want to be able to open the database, the current info that is there be
at read only, then have the ability to add a new record without a password,
then once that record has been completed, it is added to the table as
read-only as well..

Thank,

Brook
 
S

Steve Schapel

Brook,

Do you mean that with the suggestion I gave you, you are not able to add
a new record without entering the password? Sorry, I can't think of a
reason for this. The Allow Additions property of the form still set to Yes?
 
Top