


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.
V.J.
Views
Replies
Sign in to like this content
Total Likes
Hi,
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.
Else
{
submitButton1.access = "open";
submitButton2.access = "open";
}
Good luck
Stephen
Thanks for the response - one further question, please?
Code for Dropdown text
<validate nullTest="error"/>
<assist>
<speak priority="caption"/>
</assist>
<traversal>
<traverse ref="Q2Note[0]"/>
</traversal>
<items save="1">
<text>Yes</text>
<text>No</text>
<text>other person files</text>
</items>
</field>
<draw x="9.525mm" y="241.3mm" name="Q2Note" w="142.875mm" h="10.728mm">
<font typeface="Myriad Pro" baselineShift="0pt"/>
<value>
<text>You must pay the </text>
</value>
<ui>
<textEdit/>
</ui>
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
Views
Replies
Sign in to like this content
Total Likes
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"
else
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.
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.
1TL
Views
Replies
Sign in to like this content
Total Likes
Hi,
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!
Stephen
P.S. RadioButtonList is also known as ExclusionGroup (I think it depends on which version of LCD you use. S.
Views
Replies
Sign in to like this content
Total Likes
Thank you - I will keep you informed of the outcome.
Views
Replies
Sign in to like this content
Total Likes