Skip to main content
Tayran
Participant
July 12, 2017
Question

Is there a quicker way to add validation script to multiple dropdown lists?

  • July 12, 2017
  • 1 reply
  • 598 views

if (event.value=="VD") 

    event.target.fillColor = color.gray; 

else if (event.value=="OD") 

    event.target.fillColor = color.ltGray;  

else event.target.fillColor = color.transparent; 

This topic has been closed for replies.

1 reply

try67
Community Expert
Community Expert
July 12, 2017

Put the code in a doc-level function and then use a script to set the Validation action of the fields to call that function.

Tayran
TayranAuthor
Participant
July 12, 2017

Thanks!  I guess I need more than that. How do I "Put the code in a doc-level function and then use a script to set the Validation action of the fields to call that function."

try67
Community Expert
Community Expert
July 13, 2017

Do you want to apply this code to all drop-downs in your file, or just some?