Hi!
I need to create a drop down list where the options are really long. I am aware that the "drop down list field" in livecycle do not give you the option for multiple lines. Can I script the values of the drop down list using FormCalc or Javascript? This way I can hard code where the second line should start.
Yes, you can fill a dropdown list with javascript:
MyDropDown.clearItems();
MyDropDown.addItem("Item 1","1");
MyDropDown.addItem("Item 2","2");
etc.
If you want to insert multiple lines, write "\n":
MyDropDown.addItem("This is Item 3\nA very long line containing this option","2");
Thank you for your reply! I am new to this please be patient
Where do I place the code? I have to create the same field 5 times
UnitGoal1
UnitGoal2
UnitGoal3
UnitGoal4
UnitGoal5
Do I place the code in the change event of each field.
Views
Replies
Total Likes
No problem
Yes, you have to repeat the code for each item you want to populate.
You can place the code in the "initialize" event for the form or for the page the list is in. So, when you open the form, the list is already populated and ready to use.
J. Carlos
Views
Replies
Total Likes
Hi,
here's a sample of a "multi-line dropdown" I created once.
https://workspaces.acrobat.com/app.html#d=kvGJ4kTvXaZHj5g6LJpP6Q
A picture is shown in this thread
Views
Replies
Total Likes
Make the height of the DD big. In the exit of the drop down use this code
::exit
if(this.rawValue == "This is drop down"){
this.rawValue = "This is \n drop down";
}
Views
Replies
Total Likes
The line doesn't work.
Views
Replies
Total Likes
Views
Likes
Replies