Lock field in Matrix
Barney
hi ,i was trying to lock some field in PQ form by the following C# code but it not work,
string[] itemsToLock = new string[]{"11" };
LockFields(pVal.Form, itemsToLock);
return true;
can you please assist,
thanks,
Barney
Heiko Merz
I'd also be interested in that. Any ideas ?Heiko Merz
OK, maybe my solution will help:Topic: Lock Address ID field in BP - Addresses.
Optimizer Rule : CSCODE, VALIDATE, Form Type 134, Event Type FormDataLoad.
Part of Code:
Matrix m = Matrix.GetFromUID(pVal.Form, "178");
m.Columns["1"].Editable = false;
I have also another function in it that on the user master data, I created a UDF called "Update Addresses allowed".
So, for users who have this field set to "Yes", the Address ID field is Editable.
For users who have this field set to "No", the Address ID field is not Editable.
I hope that's a possible solution also for you.
Kind regards,
Heiko
0
Please sign in to leave a comment.
Comments
0 comments