Question

Add default value to field

Hi guys,

How to add a default value to a new field in any Page?

Like 0

Like

4 comments

Dear Susanna, 

You can go to System designer -> Advanced settings -> Configuration -> open the object, choose a field and set a default value there (https://prnt.sc/oob8ig).

Best regards,

Dennis 

Is there a way to do this in the edit page code? Say for example I wanted a field to be defaulted to some value based on some ESQ which runs when the page is opened? This gives more flexibility than using the Object's default values.

Edit: using this.set("UsrFieldName", value) is the answer.

You can in the business process and wrap conditions to determine the values. If these are validated values/list, you should create a lookup that you can manage outside of the BP if applicable.

Hello Harvey, 



The answer you have specified is correct to reach the described functionality. 



Kind regards,

Roman Brown

Show all comments