General
Properties | Events | Methods
All the common Properties, Methods and events against the components which will be applicable globally will be shown here.
Properties
1. Primary
Id
A unique identifier assigned to the input text box.
Name
The name of the control which used for referencing in scripts or configurations.
Caption
The label or text displayed alongside the input field.
2. Appearance
Disabled
Disables the control's input so it cannot be interacted with.
Hide
Hides the input field from view.
Mobile span
Column span of the specific control on mobile devices.
Place holder
Hint text displayed inside the specific field when empty.
Custom Style
Additional CSS styles for the control.
Style
| Field | Group | Type | Description |
|---|---|---|---|
| Style | Custom | JSON | It is used for CSS styling. Ex: {"customcolor":true,"oncolor":"#29ba50","offcolor":"#29ba50","textcolor":"#29ba50"} |
| customcolor | style | String | CustomColor should be true if color is required during ON/OFF. |
| oncolor | style | String | To set the color when turning ON, use oncolor. |
| offcolor | style | String | To set the color when turning OFF, use offcolor. |
| textcolor | style | String | To set the color of the text. |
3. Data
Value
Contains user input values
Default value
Initial value for the input when the form loads.
Bind Field
Connects the control to a specific data field to display or update its value.
Source Link
URL or path to fetch data dynamically for the input.
Data Source
It defines the database, table, API, or dataset from which data is fetched.
Required
Specifies whether the input is mandatory.
4. Others
Exclude Clone
Disable Clone functionality.
Language
User can select the language as English/Arabic/Tamil. Also can update the caption (Control) and Tooltip (Additional info) in desired language.
Help document
Link or reference to a help document.
Edit Mode Handler
Handles logic when the input enters edit mode.
Events
These events are essential for building responsive, dynamic user interfaces.
| Event | Trigger Moment | Purpose / Real-Time Usage |
|---|---|---|
| OnChange | When input value newly adds or changes | Auto-update related fields (e.g., selecting Country loads States). |
| OnKeyDown | When a key is pressed down | Trigger search on Enter, apply shortcuts, scroll actions. |
| OnAfterDataImport | After data import is completed | Show success message or refresh imported data. |
| OnLostFocus | When an element loses focus | Validate input or auto-format when user leaves the field. |
| OnSelected | When an element (row/tab/item) is selected | Load selected item details or update UI based on selection. |
| OnBeforeDelete | When delete action is initiated | Show confirmation popup or validate delete rules. |
| OnAfterDelete | After delete completes | Refresh table and show “Record deleted” message. |
| OnBeforeAdd | When add action is initiated | Check mandatory data or load defaults before opening form. |
| OnAfterAdd | After a new record is added | Reload data table and show success message. |
| OnBeforeEdit | When edit action is initiated | Check permissions or load existing record into form. |
| OnAfterEdit | After edit is completed | Refresh list and show “Updated successfully.” |
| OnAfterLoad | After data/page finishes loading | Apply default filters or run initialization logic. |
| OnRowClick | When a row is clicked | Display row details or open a detailed side panel. |
| DeSelected | When a selected item is clicked again | Clear selection and reset related UI states. |
| OnOkClick | When OK button in popup is clicked | Confirm action, close popup, and proceed with next steps. |
| OnClick | When a UI element is clicked | Submit forms, call APIs, open popups, or change properties. |
| OnDoubleClick | When an element is double-clicked | Open detail view or perform quick-access actions. |
| OnFocus | When an element gains focus | Highlight field, show hint, or prepare input validations. |
| OnLoad | When form or page finishes loading | Initialize fields, load defaults, or fetch required data. |
| OnPopupClose | When popup is closed | Refresh parent form, reload lists, or run post-actions. |
Methods
GetCtrlProperty
Retrieves the specified property value from a control using its Control ID.
Default Variant
Return Type
string | number | boolean | Date | Time| Date and Time | json |
(The return type depends on the property being accessed.)
Syntax
let <Variable Name> = GetCtrlProperty("<Control ID>", "<Property>");
Example:
let userid = GetCtrlProperty("56", "value");
Parameters
Control ID string - The unique control id
Property string - Respective control property to get the value
Variant 1
Get Data Source Column Values
Return Type
string | number | boolean | Date | Time| Date and Time | json |
Syntax
let <<Variable Name>> = GetCtrlProperty("<<Contorl ID>>", "<<Data Source Field Name>>");
Example:
let ldvalue = GetCtrlProperty("11", "patientid");
SetCtrlProperty
Set the value for the property of the control in the CRUD page.
Default Variant
Return Type
N/A
Syntax
SetCtrlProperty("<<Control ID>>", "<<Property>>", "<<Value>>");
Example:
SetCtrlProperty(12, 'disabled', true);
Parameters
Control ID string : Mention the unique Control id.
Property string : Mention the Control's Property.
Value string number boolean : Mention the value that is set to the control property.
Variant 1
Pass value to Data Table column parameter
Syntax
SetCtrlProperty("<<Data Table Control ID>>", "i:<<Data Source Field Name>>:<<Column Order No.>>:<<Parameter Name>>", "<<Control ID>>");
Example :
SetCtrlProperty(15, "i:columns:2:pnvendor", "i:4");
Parameters
i : Data Source Column Index
Data Source Field Name string : Columns
Column Order No number : Mention Column Order Number
Parameter Name string : Mention the column's parameter name
Variant 2
Set Sourcelink for Data Table
Syntax
SetCtrlProperty("<<Data Table Control ID>>", "<<SourceLink>>:<<ParameterName>>", "<<Value>>");
Example:
SetCtrlProperty(15, "sourcelink:pnvendor", "i:4");
Parameters
Parameter Name string : Mention the parameter name used in source link property
Value string boolean number : The value that is set for the mentioned parameter
Variant 3
Refresh Tile view control with value
Syntax
SetCtrlProperty("<<Control ID>>", "<<Property>>", { "<<Parameter Name>>": <<Parameter Value>> });
Example:
SetCtrlProperty("78", "refresh", { "pntype": 10 });
Parameter
Parameter Name string : Parameter name mentioned in datasource
Parameter Value string boolean number : The value that is set for the mentioned parameter
Show Alert
Show Alert Message as Toast pop-up
Return Type
N/A
Syntax
showAlert('<<Alert Message>>');
Example:
showAlert('Invalid MRN No.! Please verify the number and try again.');
Parameter
Alert Message string - Success / Warning / Error / Info / Processing / Loading
Show Alert Dialog
Show Alert Message as a Dialog
Return Type
N/A
Syntax
ShowAlertDialog("Type", "<<Message>>");
Example:
ShowAlertDialog("warning", "Please Fill the Required Field");
Parameter
Type string required - Dialog type Identifier ( Success / Warning / Error / Info / Processing / Loading)
Message string/ array required - Alert message to be displayed
Variant 1
Based on the action, the success or failure method will be executed.
Return Type
N/A
Syntax
ShowAlertDialog("Type", "Message", "AcceptFunction", "RejectFunction")
Example:
showAlertDialog("confirm", "Want to proceed?", msg);
Parameter
Type string : Dialog type identifier
Message string/ array : Content to display in dialog
AcceptFunction string : Optional Callback for positive action (OK/Yes/Delete)
RejectFunction string : Optional Callback for negative action (Cancel/No)
*Note : Alert Type - Success / Delete / Warning / Error / Info / Processing / Loading / Saveasvalid
SetGlobalVariable
Assign values to a global variable for access throughout the application.
Default Variant
Return Type
string | number | boolean | Date |
Syntax
SetGlobalVariable("<<Global Variable Name>>","<<Value>>");
Example:
SetGlobalVariable("name-4","MRN001");
Parameters
Global Variable Name string : The variable in which the value is stored.
Value string number boolean : The value of the global variable, which may come either directly or from UI controls
GetGlobalVariable
Retrieve values from a globally stored variable.
Default Variant
Return Type
Property Data Type (based on the variable data type) string | number | boolean | Date |
Syntax
GetGlobalVariable("<<Global Variable Name>>");
Example:
let mrnno = GetGlobalVariable(name-4);
Parameters
Global Variable Name string : The variable in which the value is stored.
GeoLocation
To retrieve the user's latitude and longitude using their device's location services
Return Type
Object
Syntax
const [Function Name] = async() => {
let [Variable Name] = await GeoLocation()
}
[Function Name]()
Example:
const func = async() => {
let loc = await GeoLocation()
}
func()
*Note :The correct way to execute geolocation is using 'await' inside an 'async' function.
GetDate
Returns a 'Date object' containing either the current server date and time or a specified date and time.
Return Type
Date Time
Syntax
GetDate()
Example:
GetDate()
Variant 1
To get Date object using date Date value.
Return Type
Date Time
Syntax
GetDate(<<Date>>)
Example:
GetDate("2025-05-01")
Parameters
Date string : contains the date inside the string
Variant 2
To get Date object using Date Time value.
Return Type
Date Time
Syntax
GetDate(<<Date Time>>)
Example:
GetDate("2025-12-15 16:05:35'")
Parameters
Date Time string - contains Date with Time .
RefreshPage
Used to refresh or reload a specific task, screen, or report in the application
Return Type
N/A
Syntax
RefreshPage(<<Page ID>>);
Example:
RefreshPage(2910209);
Parameters
pnid string number : Unique identifier of the page/task/report that needs to be refreshed.
RefreshParentPage
Used to refresh the previous Page/Report data source in the design.
Return Type
N/A
Syntax
RefreshParentPage({"parent":"<<Parent Object ID>>","child":"<<Child Object ID>>"});
Example:
RefreshParentPage({"parent":"2251141","child":"2251122"});
Parameters
loparent JSON : Refresh the parent object
Parent(Previous) Design Serial No./ID string : Parent Object ID (Belongs to: loparent)
Current Design Serial No./ID string : Child Object ID ( Belongs to: loparent)
ShowHelpDocument
Displays the relevant help document associated with a specific control, entry or functionality in the application.
Default Variant
Return Type
N/A
Syntax
ShowHelpDocument({helpdoc:"<<Help Document Code>>"})
Example:
ShowHelpDocument({helpdoc:"HI-3"})
Parameters
Help Document Code : This will open the help popup associated with the help document code (For eg: "HI-3") displaying relevant guidance or instructions for the linked control or feature.
The user can pass the respective code from the Help code Document page.
OpenPage
Used to open screens, tasks, reports, dashboards, or timelines dynamically using a configuration object. It supports workflows, screen modes (add/edit/view), conditional toolbars, drilldowns, and can open pages in iframes or new tabs.
Default Variant
Return Type
N/A
Syntax
OpenPage({
wfrefno: "",
wfprocno: "",
linkid: "", //Required
mode: "",
type: "", //Required
processid: "",
height: 768,
width: 800,
toolbarvisible: true,
footerclose: true,
appslno: 101,
menuname: "",
isviewonly: false,
srcdefvalues: {
empcode: "",
status: ""
},
cmnuid: "",
drilldownparam: {
date: ""
}
});
Example:
OpenPage(
{
"wfrefno":"",
"wfprocno":"",
"linkid":"3430035",
"mode":"add",
"type":"screen",
"processid":"",
"height":768,
"width":800,
"toolbarvisible" : false
}
)
Parameters
| Property | Type | Description |
|---|---|---|
| wfrefno | string | (Optional) Workflow reference number |
| wfprocno | string | (Optional) Workflow process number |
| linkid | number string | (Required) Unique identifier of the screen, task, or report to open. |
| mode | string | (Optional) Operation mode – "add", "edit", or "view". |
| type | string | (Required) Type of module to open – "screen", "task", "report", "dashboard", "timeline", or "task history". |
| processid | string | (Optional) Business process ID |
| height | number | (Optional) Custom height of the screen |
| width | number | (Optional) Custom width of the screen |
| toolbarvisible | boolean | (Optional) Set to false to hide the toolbar. Default is true. |
| footerclose | boolean | (Optional) Set to false to disable the footer’s auto-close feature |
| appslno | number | (Optional) Application ID. If not provided, it's pulled from local storage. |
| drilldownparam | object | (Optional) Parameters used in drilldown views |
| cmnuid | string | (Optional) Common UID to trigger iframe/external app |
| srcdefvalues | object | (Optional) Default values passed to the screen |
| menuname | string | (Optional) Menu name to be displayed |
| isviewonly | boolean | (Optional) Set to true to make the screen read-only |
PrintDocument
Used to call the print document against the respective source
Default Variant
Return Type
N/A
Syntax
PrintDocument({},<Print Document ID>,"")
Example:
function print() {
PrintDocument({},3001361,"")
}
Parameters
Print Document IDNumber : defines Print Document Design ID
CallFormEvent
Used to execute toolbar actions on the CRUD page.
Default Variant
Return Type
N/A
Syntax
CallFormEvent("<<Toolbar Action Name>>");
Example:
CallFormEvent("Submit");
Parameters
Toolbar Action Name String : following are the list of actions
| Action | Description |
|---|---|
Add | Opens the form to add a new record. |
Edit | Enables editing of the selected record. |
Submit | Submits the current form data. |
Close | Closes the current form or page. |
HideClose | Hides the close button on the form. |
Search | Triggers a search operation. |
Print | Prints the current record or form. |
Approve | Approves the current record. |
Review | Sends the record for review. |
Reject | Rejects the current record. |
Task History | Displays the task history. |
Draft Save | Saves the form data as a draft. |
Restore | Allows to load the fresh form. |
Delete | Deletes the selected record. |
Refresh | Refreshes the data or form view. |
Load | Loads the form or data again. |
GetLocalStorage
Access values from session storage
Default Variant
Return Type
string|number|date|time|date and time|
Syntax
let <<Variable Name>> = GetLocalStorage("<<key>>");
Example:
let userid = GetLocalStorage("usercode");
Parameters
Key string : Name used to store and retrieve the value
SetLocalStorage
Set a value in session storage
Default Variant
Return Type
string|number|date|time|date and time|
Syntax
SetLocalStorage("<<Key_ID>>","<<key_value>>")
Example:
SetLocalStorage("usercode","1005")
Parameters
Key ID string : Unique Id for storing data in local browser.
Key Value object : Name used to store the value.
CallParentControlEvents
Executes the parent control's event method from a event.
Default Variant
Return Type
NA
Syntax
CallParentControlEvents(psdata);
Example:
CallParentControlEvents([{"ctrlid":"72",event:"onClick"}]);
Parameters
psdatajson : A JSON array where each object represents a control event to trigger.
ctrlid integer : The ID of the control on which the event should be triggered.
event String : The name of the event that wants to be triggered (e.g., "onClick", "onChange",etc..)
ControlsValidaton
Validates whether the specified controls marked as 'Required: true' are filled. If any required field is empty, the function returns false and displays the message: “Please fill the mandatory field.”
Default Variant
Return Type
NA
Syntax
Controls Validation(id);
Example:
Function Submit Form() {
if (!Controls Validation(["20", "40"])) return alert("Please fill all required fields.");
alert("Form submitted successfully!");}
Parameters
id String : Control ID (required) – Give one or more control IDs as a comma-separated array... like [34,677,12]
** Applicable Controls - Drop Down, Input Text , Input Number
SetLoading
To show a loading spinner.
Default Variant
Return Type
N/A
Syntax
SetLoading(value)
Example:
SetLoading(true);
Parameters
value boolean : returns true or false
ChangeWorkflowProcess
Allows to create a custom workflow to some specific needs
Default Variant
Return Type
N/A
Syntax
ChangeWorkflowprocess(psJsonData)
Example:
ChangeWorkflowprocess({"Workflowno":"400321","Wfprocno":"Ijd1AQeSre"})
Parameters
psJsonData string : Change Workflow Process in Json format.
Workflowno number : Mention the workflow object id
Wfprocno string : Mention the workflow process id
ConsoleLog
Used to view the values contained in the received data. To access this, open your browser's Developer Tools, go to the Inspect option, and navigate to the Console tab to check the output.
Default Variant
Return Type
N/A
Syntax
ConsoleLog(psData);
Example:
ConsoleLog("Welcome to Sterlo" );
ConsoleLog("Welcome to "+ lsUserName);
Parameters
psData string : Using console.log(variable), prints the variable based on its string,number, etc.
ShowInPopup
Show controls in the popup, based on control 'Show In Popup' property configuration.
Default Variant
Return Type
string | number | date | time | date and time |
Syntax
ShowInPopup(<<Value>>);
Example:
ShowInPopup(true);
Parameters
value string : If showInPopup is set to true, the screen opens as a popup in the preview. If set to false, the popup does not appear. Configure this JSON value in the showInPopup property of the control that needs to be shown.
GetReportCtrlProperty
Allows to retrieve data or properties from a report control, such as selected rows, filter values, or control states.
Default Variant
Return Type
string | number | boolean |
Syntax
GetReportCtrlProperty("<Control ID>", "<Property>");
Example:
GetReportCtrlProperty("12","value");
Parameters
Control ID string : Unique control id
Property string : Respective control property to get the value
IsApplicableRoles Function
Role Check Is Applicable Role The user's role is applicable for the module and shows or hides .true - Role is applicable - will be shown ,false - Role is not applicable - will be hidden
Default Variant
Return Type
Boolean
Syntax
let Is rule = Is Applicable Roles(application Number, role Number)
Example :
let rule = Is Applicable Rules(940,2070);
Parameters
appno boolean : Access based on application number is being checked.
roleno boolean : Access based on role number is being verified.
Variant 1
Visible
Return Type
Boolean
Syntax
let rule = Is Applicable Rules(appNo, roleNo)
let rule = Is Applicable Rules(940,2070);
Variant 2
Hidden
Return Type
Boolean
Syntax
let rule = Is Applicable Rules(appNo, roleNo)
Example :
let rule = Is Applicable Rules(940,2070);
fnlCallbackHandleEvent
Handles pre-submit logic; it controls whether to proceed or cancel submission based on async validations or actions. Pass true to submit, false to cancel.
Default Variant
Return Type
NA
Syntax
fnlCallbackHandleEvent(value)
Example :
fnlCallbackHandleEvent(true);
Parameters
value boolean :It Should return true or false
CallApi
Call API is used to interact with the backend, using GET to retrieve data and POST to insert or update it.
Default Variant
Return Type
Object
Syntax
Call API(poParams)
Example :
CallApi({ method: "get", lookup: "dpcrud/rt", params: { id: 50234, ver: -1, alias: -1, lparams: { "pnid": psslno } }, toa: "o" });
| Property | Type | Description |
|---|---|---|
| poParams | JSON | Contains all required details for the API request, such as HTTP method, API endpoint, parameters, and response type. |
| method | String | HTTP method to be used for the API call. Examples: "get", "post" |
| lookup | String | API Endpoint or Route Path where the request is to be sent |
| toa | String | Type of API response. Example: "o" means return response as object (Optional) |
| params | String | API parameters (supports nested objects for complex data). These are query parameters or request body values. (Optional) |
| body | String | Request body for POST requests (Optional) |
| tca | String | Additional authentication control (Optional) |
| dn | String | Domain name (Optional) |
| actproj | String | Active project ID (Optional) |
| actapp | Boolean | Active application ID (Optional) |
| cachetype | String | Cache type ("L" for Local) (Optional) |
| isdesign | Boolean | Design mode flag (Optional) |
| skpds | Boolean | Skip data source processing (Optional) |
| datasource | String | Data source configuration (Optional) |
*Note - It is used as Direct code both in static and dynamic screen
