version 6.0 (Modified)
SET ENTERABLE ({*; }entryArea; enterable)
| Parameter | Type | Description | |
| * | If specified, Object is an Object Name (String) | ||
| If omitted, Object is a Field or a Variable | |||
| entryArea | Form Object | Object Name (if * is specified), or | |
| Field or Variable (if * is omitted) | |||
| enterable | Boolean | True for enterable; False for non-enterable |
Description
The command SET ENTERABLE makes the form objects specified by object either enterable or non-enterable.
If you specify the optional * parameter, you indicate an object name (a string) in object. If you omit the optional * parameter, you indicate a field or a variable in object. In this case, specify a field or variable reference (field or variable objects only) instead of a string. For more information about object names, see the section Object Properties.
Using this command is equivalent to selecting Enterable or Non-enterable for a field or variable in the Form Editor's Object Properties window. This command works in subforms only if it is in the form method of the subform.
When the entryArea is enterable (TRUE), the user can move the cursor into the area and enter data. When the entryArea is non-enterable (FALSE), the user cannot move the cursor into the area and cannot enter data.
Making an object non-enterable does not prevent you from changing its value programmatically.
Example
The following example sets a shipping field, depending on the weight of the shipment. If the shipment is 1 ounce or less, then the shipper is set to US Mail and the field is set to be non-enterable. Otherwise, the field is set to be enterable.
If ([Shipments]Weight<=1) [Shipments]Shipper:="US Mail" SET ENTERABLE([Shipments]Shipper;False) Else SET ENTERABLE([Shipments]Shipper;True) End if
See Also
DISABLE BUTTON, ENABLE BUTTON, SET VISIBLE.