Skip to content
🚀 Rapid Application Development with the App Builder

onChange

The onChange event occurs when the value of an HTML element is changed. ↗️

Parameters

ParameterTypeDescription
eventobjectEvent object.
modeenumINSERT | UPDATE | VIEW
columnNamestringThe name of the database table column.
getColumnValuefunctionSee getColumnValue(columnName)
setColumnValuefunctionSee setColumnValue(columnName, columnValue)
setColumnStylefunctionSee setColumnStyle(columnName, cssStyle)

Return Value

None

✨ Example

js
((event, mode, columnName, getColumnValue, setColumnValue, setColumnStyle) => {

	wpda.log.info("message from onChange", event, mode, columnName, getColumnValue())
  
})

Notes

  • The getColumnValue function returns the old column value. The new column value is available in event.target.value.
  • Do NOT use setColumnValue to update the field value. This is done internally. Use this hook to add custom bahavior only.
  • The onChange hook does not work on lookup columns.