I have dropdown box with list of predifined items, from which I can select items into a text field with an add and remove buttons. these all work very nice.
Currently I have to remove one by one item incase I made some wrong selections via the remove button. You need to select the item and then click remove to have the item remove.
the section under the remove button is as below and work 100%
I would now like to add another button to "clear all" selections from the text field without the necessity to first select the item. When I click CLEAR ALL button all of the selections should be cleared..
any idea how to write the statement to clear ALL selections from text box.
Thank you kindly.
I already have a reset button added to my form to clear everything completely and do use the following script
The "reset" button do clear all normal data fields but even the RESET button do not clear the data entered into a text field from a drop down selection.
I can delete one item at a time by selecting the value and then click remove.
I want to add another button that say "Remove All" and then all the values selected must be removed from this text field.
the current script for "Remove" button is.
I just want to change the above code that I can add to my REMOVE ALL button, to delete ALL items and not only the selected one.
I am new to adobe forms forum. how do you upload a form so that you can see?
The resetData() will clear all data. The example above is intended to show how you can target specific fields.
However you want to remove specific sections within the textfield, which will require the replace() method. This is where you look for a match in the textfield's .rawValue and replace it with an empty string "".
You can't upload files directly to the forums, but if you put it in a file sharing site and post the published link here I will have a look at it when I can.
Thank you Niall
let me find a site where I can upload the form. any recommendations for sites you normally use.
In the mean time I will spend some more time on this and see where I am missing the plot..
I would recommend Acrobat.com, but please bear in mind that you need to Publish the file before it is available to anyone else.
Have a look at this example I did up for someone else. https://acrobat.com/#d=6hEiR5CSyQe1yUiqWXwEbg. Here it is looking at the rawValue of the listbox and stripping out the newlines (\n).
It might help,
after some more investigating I found something that will clear this.
Never thought about a "clear", was struggling with reset etc..
Thank you so much for your help.