Choose where you’d like to start

Enable | Disable

Note: This task is applicable only to Zoho Creator.

Overview

The Disable deluge task disables a specified field on the form. The disabled field will be grayed out, and the user will not be able to add data to that field.

The Enable deluge task reverses the Disable action and re-enables a disabled field for users to fill it out in the form.

Note:

Syntax

To disable a field

disable <field_link_name>;
 

To disable a subform field

disable row.<subform_field_link_name>;
 

To enable a field

enable <field_link_name>;
 

To enable a subform field

enable row.<subform_field_link_name>;
ParamExplanation
<field_link_name> & <subform_field_link_name>

Link name of the field which needs to be disabled or re-enabled.

Points to keep in mind for this parameter:

  • Since the Autonumber field type is not displayed in a form, it cannot be specified in this task.
  • For composite field types like Name and Address, the action of disabling/enabling the main field will be applied to all its subfields, by default.  To enable/disable a particular subfield you must specify it along with the main field, for example: disable Name.last_name;
  • The action of disabling/enabling the Section field type is not supported.

This task can be used in the following events

When a record is Created
Workflow eventFor form fieldsFor subform fields
On LoadYesNo
On ValidateNoNo
On SuccessNoNo
On User inputYesNo
On user input of a subform fieldNoYes
Subform on add rowYesYes
Subform on delete rowYesYes
When a record is Created or Edited
Workflow eventFor form fieldsFor subform fields
On LoadYesNo
On ValidateNoYes
On SuccessNoNo
On User inputYesNo
On user input of a subform fieldNoYes
Subform on add rowYesYes
Subform on delete rowYesYes
When a record is Edited
Workflow eventFor form fieldsFor subform fields
On LoadYesNo
On ValidateNoNo
On SuccessNoNo
On User inputYesNo
On user input of a subform fieldNoYes
On UpdateYesNo
Subform on add rowYesYes
Subform on delete rowYesYes
When a record is Deleted
Workflow eventFor form fieldsFor subform fields
On ValidateNoNo
On SuccessNoNo
Other workflow events
Workflow eventFor form fieldsFor subform fields
On a scheduled dateNoNo
During approval processNoNo
During payment processNoNo
In a Custom FunctionNoNo
In an Action item in reportNoNo

Example 1

  • The following snippet disables the "Total Amount" field.
disable Total_Amount;

Example 2

  • The following snippet disables the cost field in the subform of the order placement form.
disable row.cost;

Scenario 1: Enabling field in a job application form

Consider a job application form where there is a decision box field to distinguish the experienced and fresher candidates category. Based on the user input of the decision box field, the number field to record the years of experience will be enabled or disabled. If the candidate selects the category as experienced, the number field wiI ll be enabled to to get work experience.

if ( category == "experienced") 
{ 
enable experience_in_years; 
} 
else 
{ 
disable experience_in_years; 
}

Get Started Now

Execute