Highlighted

Dropdown to populate textbox with multiple selections

Avatar

Guest

14-05-2008

I'm doing a simple form for a process at work and thought it should be really simple. I placed a list-box on the form so as users could make multiple selections (Ctrl+click). Now the business unit has come back saying they want to swap the list box for a drop-down list, and have the drop-down populate a text box with multiple selections (on change or click). I'm not a coder and have looked for something similar but haven't been too lucky in my search.



I picked up the piece of code below which populates the text box, but it always replacs the first seletion with a different selection. Can anyone please help modify this code so it adds mutiple choices to the text box.



SelectedInd.rawValue = xfa.event.newText;



Many regards

Replies

Highlighted

Avatar

Guest

14-05-2008

if(xfa.event.prevText=="")

{

SelectedCat.rawValue = xfa.event.newText;

}

if(xfa.event.prevText!="")

{

SelectedCat.rawValue = SelectedCat.rawValue+"\n"+xfa.event.newText;

}



this script will work.SelectedCat is the textField which are you are populating
Highlighted
Highlighted

Arnold_L

15-02-2009

Hello,



I'm a new user to Adobe Live Cycle. I have the same problem with a drop down and a text field box.



I have a drop down with multiple selections and have a text field that generates text. I wanted to keep that text but it disappears after the next selection.



I've tried using the code provided above but had no sucess.... I placed the code everywhere I could think of.

change, exit, with the trigger drop down & the text field box.



This is would be awesome if someone could help me with my form.



I have the same problem with Checkboxes.



Mutiple checkboxes with 1 text field. the text never stays after a new checkbox is selected.



Arnold Love

arnoldl0ve@yahoo.com