In this example, the matchcode field is validated on change to check whether it only contains 3 characters.
1.Open the Operation Catalog from Administration>Setup>Production>Operation catalog.
2.Open an operation.
3.Open the beas script editor from Tools>Extension for Clients or use the CTRL+N+U shortcut.
4.In the right panel find the update event and double-click to add the event to the editor.
5.Add the code to the event.
// ******* Event dw_1_update ********
// Created 2019/01/29 by manager
global function dw_1_update
setvar=ll_length=%len(<dw_1.item.matchcode.value>)
if <ll_length> <> 3 then
messagebox=Lenght is not 3 characters.
end if
end global
The message is displayed, when the Update button is clicked and the field length is not 3 characters.
Field Validation Message
For details on creating the variable, see setvar.
For details on the data window, see dw_1 (dw_2, dw_3...dw_7, dw_edit).