Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

SOLVED

How to do newline in Validation Script Message

Avatar

Level 4

Hi

im trying to write a multiline error message in the Validation Script Message for a textfield but everytime I hit return, i end up at the front of the current line instead of a new line.  I've also tried \n with no luck.  The only way i've found is by entering the text into notepad and then cut+paste into the Validation Script Message box.  Is this a bug with Designer?  I have Designer ES 8.2.1.3158.1.475346.

ValScriptMesgEd.JPG

I am aware of how to do it by script  ex.  this.validationMessage = "line1\nline2" but what i want to is store the Section and field name in the Validation Script Message box and then build the error message ontop via script.

ex.

this.validationMessage = this.validationMessage + "Validation failed due to ....";

1 Accepted Solution

Avatar

Correct answer by
Level 10

Just tested this and it looks like ctrl-enter works.

View solution in original post

2 Replies

Avatar

Correct answer by
Level 10

Just tested this and it looks like ctrl-enter works.