dbTalk Databases Forums  

Locking a record from being edited?

comp.databases.filemaker comp.databases.filemaker


Discuss Locking a record from being edited? in the comp.databases.filemaker forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
DavidR
 
Posts: n/a

Default Locking a record from being edited? - 01-24-2007 , 02:59 PM






Hi:

I have a DB that based on certian criteria i want to become
non-modifable.. Its a PO Database that after the print script runs,
that the record is considered Locked and none of the fields may be
modified.

Anyone have advice on how I can do this? FMP 8.5 Win


Reply With Quote
  #2  
Old   
KevinSmith
 
Posts: n/a

Default Re: Locking a record from being edited? - 01-24-2007 , 05:59 PM






Hi David

Create a numeric field called "Locked_Flag". This field can be set to 1
or 0. It's locked when set to 1.

Here are methods a and b

a) Now, for every field that you don't want to be modifiable, set a
validation criterion:
"Locked_Flag=0" If it's set to "1" instead, ie locked, the field will
fail validation. User will get a dialogue box warning her not to edit.

b) The weakness of method "a" above is that you have to go around
setting the field validation for most of the user editable fields in
that table.

Have two layouts. "Invoice_Editable" and "Invoice_ViewOnly". On the
"Invoice_ViewOnly" layout have the words "Locked" displaying in bold
somewhere. Make sure that all the user fields have their "behaviour"
set to "not modifiable". Don't forget to deactivate any buttons on the
layout that modify data.

The weakness of this approach is that you now have two layouts that
need modifying everytime you add a field etc

Regards
Kevin



On 24 Jan, 20:59, "DavidR" <davidcr... (AT) gmail (DOT) com> wrote:
Quote:
Hi:

I have a DB that based on certian criteria i want to become
non-modifable.. Its a PO Database that after the print script runs,
that the record is considered Locked and none of the fields may be
modified.

Anyone have advice on how I can do this? FMP 8.5 Win


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.