Prepopulate values in multifield

Avatar

Avatar
Validate 10
Level 2
rk39193348
Level 2

Like

1 like

Total Posts

92 posts

Correct reply

1 solution
Top badges earned
Validate 10
Validate 1
Boost 1
Affirm 1
View profile

Avatar
Validate 10
Level 2
rk39193348
Level 2

Like

1 like

Total Posts

92 posts

Correct reply

1 solution
Top badges earned
Validate 10
Validate 1
Boost 1
Affirm 1
View profile
rk39193348
Level 2

02-05-2017

 Hi,

I have a scenario where I need to prepopulate values inside multifield. How to achieve this? Please help?

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Boost 3
Level 2
Naresh_Katkam
Level 2

Likes

4 likes

Total Posts

8 posts

Correct reply

3 solutions
Top badges earned
Boost 3
Boost 1
Affirm 3
Affirm 1
View profile

Avatar
Boost 3
Level 2
Naresh_Katkam
Level 2

Likes

4 likes

Total Posts

8 posts

Correct reply

3 solutions
Top badges earned
Boost 3
Boost 1
Affirm 3
Affirm 1
View profile
Naresh_Katkam
Level 2

04-11-2017

Hi

you have to write loadcontent event js to prepopulate values.

In JS you have to add a item first based on the condition check and add values to that multifield.

example:

loadcontent js

if(multifield.getValue()=='')

{

     multifield.addItem();

     if{

          here you can write your logic to set prepopulate values.

}

if you need any further help. just let me know.

Thanks.

Answers (2)

Answers (2)

Avatar

Avatar
Boost 50
Level 5
James_R_Green
Level 5

Likes

52 likes

Total Posts

191 posts

Correct reply

47 solutions
Top badges earned
Boost 50
Validate 25
Validate 10
Validate 1
Boost 5
View profile

Avatar
Boost 50
Level 5
James_R_Green
Level 5

Likes

52 likes

Total Posts

191 posts

Correct reply

47 solutions
Top badges earned
Boost 50
Validate 25
Validate 10
Validate 1
Boost 5
View profile
James_R_Green
Level 5

04-05-2017

Hi,

Do you mean the "Drop-down List" Adaptive Form component with Allow multiple selection checked?

If so, you can just configure with the spanner and add options under the items property.

Or you can add them with javascript using the Rules editor (hammer tool) and populate with code similar to this:

 
    
    var testValues = ["1", "2", "3"]; this.items = testValues;
 

Avatar

Avatar
Validate 10
Level 2
rk39193348
Level 2

Like

1 like

Total Posts

92 posts

Correct reply

1 solution
Top badges earned
Validate 10
Validate 1
Boost 1
Affirm 1
View profile

Avatar
Validate 10
Level 2
rk39193348
Level 2

Like

1 like

Total Posts

92 posts

Correct reply

1 solution
Top badges earned
Validate 10
Validate 1
Boost 1
Affirm 1
View profile
rk39193348
Level 2

02-05-2017

rk39193348 wrote...

 Hi,

I have a scenario where I need to prepopulate values inside multifield. How to achieve this? Please help?

 

Also I need the values entered inside my multifield to stay in dialog. How to achieve this?

My dialog contains 9 text field and 1 dropdown field inside multifield. The values should be prepopulated inside the dialog