rbf_setFieldReadOnly()

Warning: Support for using this method with external objects (such as those mapped to external tables, to OpenEdge Service objects, or through a HDP connection) is a beta feature. This method is supported in production systems, except for external objects.

Purpose

This function marks an input field to remain read-only on the current page. It will have no effect if the field does not exist on the current page. For fields that allow values in multiple languages, use the options parameter to specify which language the input field remains read-only. If the language code is invalid, or is not included in the tenant's supported languages, the field doesn't remain read-only.

Note: Only text field and text area fields support the read-only attribute.

Syntax

rbf_setFieldReadOnly(fieldname, isReadOnly, options)

Parameters

fieldName

The integration name of field

isReadOnly

The boolean value for "read-only" field's property

options

A JSON object containing langCode, whose value is an array of two-letter ISO language codes, for example, {"langCode":["ar","he","fr"]}. The field will be disabled/enabled for those languages.

Note: This API is supported in portals as well.

Example

The following example marks an input field empId to remain read-only.

rbf_setFieldReadOnly("empId",true,{"langCode":["ar","he","fr"]} )