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
BedrockMission!

Learn more

View all

Sign in to view all badges

SOLVED

how could I add a message that appear when you open the form

khaldoona993089
Level 3
Level 3

how could I add a message that appear only when you open the Form 1st time

and this message contain text with multi lines

exactly like this :

befor you begain.jpg

I need the  whole the code  , and where could I put it   please

I mad this photo on photoshop

Adobe Experience Manager Forms

1 Accepted Solution
Mayank_Gandhi
Correct answer by
Community Advisor
Community Advisor

to call a script on form initialize place the script on the docReady event:

1655498_pastedImage_0.png

Once you create the script you can edit in the script editor:

1655499_pastedImage_1.png

View solution in original post

8 Replies
Mayank_Gandhi
Community Advisor
Community Advisor

You can put the message on form initialise of guideroot container.

khaldoona993089
Level 3
Level 3

this code give the message

===========

xfa.host.messageBox("   السلام عليكم ورحمة الله وبركاته ... يعطيك قالب التقارير تعليمات مباشرة عن مكوناته وكيفية التعامل مع حقوله    كل ما عليك فعله هو وضع زر الماوس على الحقل لتعرف المطلوب ", "Alert", 3);

but I need the message apear on there lines :

first line :

السلام عليكم ورحمة الله وبركاته

2nd line :

يعطيك قالب التقارير تعليمات مباشرة عن مكوناته وكيفية التعامل مع حقوله

3rd line :

يعطيك قالب التقارير تعليمات مباشرة عن مكوناته وكيفية التعامل مع حقوله    كل ما عليك فعله هو وضع زر الماوس

==how can write the code to make the message on 3 lines ?

James_R_Green
Level 7
Level 7

Have you tried inserting \n

It may insert a new line character.

E.g.

"Abc def"

"Abc\n def"

Ravi_Pampana
Community Advisor
Community Advisor

In html string you can try adding <br> for new line

"This text contains<br>a line break."

Mayank_Gandhi
Community Advisor
Community Advisor

Use this

xfa.host.messageBox("السلام عليكم ورحمة الله وبركاته\u000a يعطيك قالب التقارير تعليمات مباشرة عن مكوناته وكيفية التعامل مع حقوله \u000a يعطيك قالب التقارير تعليمات مباشرة عن مكوناته وكيفية التعامل مع حقوله    كل ما عليك فعله هو وضع زر الماوس ");

Thanks,

Mayank

Mayank_Gandhi
Correct answer by
Community Advisor
Community Advisor

to call a script on form initialize place the script on the docReady event:

1655498_pastedImage_0.png

Once you create the script you can edit in the script editor:

1655499_pastedImage_1.png

View solution in original post

khaldoona993089
Level 3
Level 3

thanks Mayank .. thank you so much

I have have one more Q  .. hope you can help me

https://forums.adobe.com/message/10836233#10836233

Mayank_Gandhi
Community Advisor
Community Advisor

Great that the solution worked for you!

I will check and let you know about the other question also.

Thanks,

Mayank Gandhi