Client Script for Mobile Apps
Introduction
The Client Script feature in Zoho CRM is not limited to the web platform but also extends its functionality to mobile applications. This versatility allows it to integrate seamlessly and operate across different environments, enhancing its usability and reach. Users can experience consistent behavior and features whether they access through a web browser or a mobile app. Client Script works in both iOS and Android Mobile Apps.
For instance, consider that you want to display an error or an info message in the mobile app whenever the user toggles a button. You can see how this works in a mobile app in the following gif.
Supported Pages and Events
| Page Type | Supported Events |
|---|---|
| Create Page (Standard) | Page Events: onLoad, onChange, onSave Field Events: onChange, onType Subform Events: onCellChange, onRowAdd, beforeRowDelete, onRowDelete Custom Button: onClick |
| Edit Page (Standard) | Page Events: onLoad, onChange, onSave Field Events: onChange, onType Subform Events: onCellChange, onRowAdd, beforeRowDelete, onRowDelete Custom Button: onClick |
| Clone Page (Standard) | Page Events: onLoad, onChange, onSave Field Events: onChange, onType Subform Events: onCellChange, onRowAdd, beforeRowDelete, onRowDelete Custom Button: onClick |
| Create Page (Wizard) | Wizard Events: onLoad, onChange, onTransition, onBeforeTransition, onBeforeSave Field Events: onChange, onType Subform Events: onCellChange, onRowAdd, beforeRowDelete, onRowDelete Custom Button: onClick |
| Edit Page (Wizard) | Wizard Events: onLoad, onChange, onTransition, onBeforeTransition, onBeforeSave Field Events: onChange, onType Subform Events: onCellChange, onRowAdd, beforeRowDelete, onRowDelete Custom Button: onClick |
| Detail Page (Standard) | Page Events: onLoad Mandatory Form: onBeforeMandatoryFormSave, onMandatoryFormLoad Blueprint Events: beforeTransition, afterTransition Subform Events: onCellChange, onRowAdd, beforeRowDelete, beforeRowUpdate, onRowDelete Custom Button: onClick |
| Detail Page (Canvas) | Page Events: onLoad Mandatory Form: onBeforeMandatoryFormSave, onMandatoryFormLoad Blueprint Events: beforeTransition Canvas Button: onClick Icon Event: onClick Text Event: onClick |
Sample Scenario
Whenever you save a Leads record with duplicate info, such as Email or Phone number, you can compare other records’ value for the same fields and restrict the user from saving the record and also throw an error message.
Here is how the above Client Script requirement works in a mobile app.
Click here to view the ZDK documentation.