Groups | Blog | Home
all groups > coldfusion flash integration > may 2005 >

coldfusion flash integration : Disable Field in Flash Form?



arastra
5/17/2005 12:00:00 AM
Hi
I have a FlashForm with just regular input fields and with radionbuttons.
I want to disable one of the Inputfields if the User selects a certain Radion
button.
This happens before the user submits!
I can't use java or actionscript because I'm using a FlashForm.
May be it works with the onclick-Event in the Radiobutton but how?
So in the onclick-Event I want to say "change the enabled-attribut of my
inputField to "No".
How do I call my InputField and how can I change the Attribut.

onclick="fieldyouwanttodisable.enabled=NO" does not work right!

Any help would be appreciated.
Sara
hollyjones
5/17/2005 12:00:00 AM
You can do this:

<cfform name="mainform" width="600" format="flash">
<cfinput type="text" name="txtName" value="Hello" width="200">
<cfinput type="radio" name="rdoEnable" value="0" label="false"
onclick="{txtName.enabled = false}">
<cfinput type="radio" name="rdoEnable" value="1" label="true"
onclick="{txtName.enabled = true}">
</cfform>

Holly
arastra
5/17/2005 12:00:00 AM
Thank you so much Holly!!!! :)
It worked.

AddThis Social Bookmark Button