Expand my Community achievements bar.

Help coding text for a textbox selection


Level 1

Hi All,

We have created an interactive form using LC Designer ES Vs8.2.1.4029...

the form turned out great, but now we have been asked to make the following change.

1.  from a dropdown list, a user can select yes, no, or agency.

2.  If they choose no, a message box should appear stating they cannot continue

3. To insure they cannot proceed if they select no, both submit buttons should be disabled.

would this be easier to figure out with radio buttons?

Please let me know if I've left out any details.

Thanks for any and all help.


6 Replies


Level 7


On the exit event of the dropdown, you need to test for "No"

if(this.rawValue == "No")


     submitButton1.access = "nonInteractive";
     submitButton2.access = "nonInteractive";

Of course, you'll need the correct SOM for you buttons and you could use the value "0" (or whatever you assign in the Binding Tab of the Object Pallet) instead of "No" if you prefer.

And, you might want to add an "Else" if they change their mind.

     submitButton1.access = "open";
     submitButton2.access = "open";


Good luck



Level 1

Thanks for the response - one further question, please?

Code for Dropdown text


<validate nullTest="error"/>
               <speak priority="caption"/>
               <traverse ref="Q2Note[0]"/>
            <items save="1">
               <text>other person files</text>
         <draw x="9.525mm" y="241.3mm" name="Q2Note" w="142.875mm" h="10.728mm">
            <font typeface="Myriad Pro" baselineShift="0pt"/>
               <text>You must pay the </text>

Because Novice is too high a position for me to hold, can you tell me if i'm on the right track -

I should not change anything in the above text, but should code on the two different submit buttons?

Would this be easier with radio buttons?

You Rock KingPhysh!

Thank you for responding!

Message was edited by: 1techylady


Level 5

May be I'm not much clear on your requirement, what I understand is you have to disable your submit buttons and you want to write that code on that button itself.

In the submit button layout ready event,

if (dropdown1.rawValue == "Yes" )

this.access = "readOnly" or (this.access = "nonInteractive"


this.access = "open";

As layout ready event executes for every object on the form for each interactive event on the form, your submit button should become readonly automatically.


Level 1

Thank you so much kc_chaitu and kingphysh.  I will be testing both options today.  I was thinking that the form could be tweaked to make the options radio buttons instead of a dropdown list and the code could be written against the "No" radio button.

I promise to post as soon as I've tried both suggestions.



Level 7


Place your script on the "change" event of the "RadioButtonList" object---not on the "No" radio button itself. I always like to use "0" for No and "1" for Yes (you assign this in the Binding Tab in the Object Pallet of the RadioButtonList).

Good luck!


P.S.  RadioButtonList is also known as ExclusionGroup (I think it depends on which version of LCD you use.   S.


Level 1

Thank you - I will keep you informed of the outcome.

page footer