How can I customize error messages from SmartGWT? (Not asking about i18n)

StackOverflow https://stackoverflow.com/questions/21608267

  •  08-10-2022
  •  | 
  •  

I am trying to get customized messages from SmartGWT (e.g. change "Must be a date" for another custom message). How can I get that String before it is shown to the user so I can edit it?

The question is for FormItem subclasses.

有帮助吗?

解决方案

You can try the following:

dynamicForm.setFieldErrors(fieldName, errorText, true);

Here is the link for documentation.

Or the following is also similar:

dynamicForm.setErrors(map, true);

Here is the link for documentation.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top