Copy link to clipboard
Copied
I have a flash form with a fair amount date fields. I use the code
<cfinput type="datefield" name="DATE1" label="Diagnosis Date:" width="100" value="#now()#"/>
This is the master date field. It populates about 10 other date fields by using the following code for the other 10 fields.
<cfinput type="datefield" name="DATE2" label="Diagnosis Date:" width="100" bind={DATE1.txt}/>
There are certain cases where date fields 7-10 are not used. Unfortuantely, fields 7-10 in those cases are prepopulated because of the bind. I want to put a reset/clear button besides each of those date fields (7-10). Is there a way to code the reset/clear button to only clear the corresponding date field? Right now, I have the users choosing the same date as DATE1 to clear out the field. That is 2 clilcks. I would prefer the users just to click on a reset/clear button.
TIA!
Put this in your pipe. Does it smoke?
<cfform format="flash">
<cfformgroup type="horizontal">
<cfinput type="datefield" name="DATE1" label="Diagnosis Date 1:" width="100" value="#now()#"/>
</cfformgroup>
<cfformgroup type="horizontal">
<cfinput type="datefield" name="DATE2" label="Diagnosis Date 2:" width="100" bind="{DATE1.text}"/>
<cfinput type="button" name="date2button" onclick="{DATE2.text=''}" value="Reset Date 2">
</cfformgroup>
<cfformgroup type="horizontal">
<cfinput type="datefield" name="DATE3
Copy link to clipboard
Copied
Put this in your pipe. Does it smoke?
<cfform format="flash">
<cfformgroup type="horizontal">
<cfinput type="datefield" name="DATE1" label="Diagnosis Date 1:" width="100" value="#now()#"/>
</cfformgroup>
<cfformgroup type="horizontal">
<cfinput type="datefield" name="DATE2" label="Diagnosis Date 2:" width="100" bind="{DATE1.text}"/>
<cfinput type="button" name="date2button" onclick="{DATE2.text=''}" value="Reset Date 2">
</cfformgroup>
<cfformgroup type="horizontal">
<cfinput type="datefield" name="DATE3" label="Diagnosis Date 3:" width="100" bind="{DATE1.text}"/>
<cfinput type="button" name="date3button" onclick="{DATE3.text=''}" value="Reset Date 3">
</cfformgroup>
</cfform>
Copy link to clipboard
Copied
It is smoking really well. Very Smooth!