The protection setting of a column. The Protect property overrides tab order settings. When a column is protected, the user cannot edit it even if the column’s tab order is greater than 0.

A column
PocketBuilder dot notation:
dw_control.Object.columnname.Protect
Describe and Modify argument:
"columnname.Protect { = ' integer ' }"
| Parameter | Description | 
|---|---|
| columnname | The name of the column for which you want to get or set the protection. | 
| integer | (exp) A boolean integer specifying whether the column is protected. Values are: 
 
 Integer can be a quoted DataWindow expression. | 
A user cannot change a column value if any one of these conditions are true:
TabSequence is 0
Edit.DisplayOnly is Yes when the column has the Edit edit style
Protect is 1
Only the Protect property allows you to specify a conditional expression that makes some values in the column protected but not others.
Select the control and set the value in the Properties view, General tab (use a conditional expression).
string setting
setting = dw_1.Object.emp_stat.Protect
dw_1.Object.emp_stat.Protect=1
setting = dw_1.Describe("emp_stat.Protect")
dw_1.Modify("emp_stat.Protect=1")
dw_1.Modify("emp_stat.Protect='1~tIf(IsRowNew(),0,1)'")
| Copyright © 2004. Sybase Inc. All rights reserved. |   | |