I just whipped this up for you - hopefully you can get the idea from this..

<script language="JavaScript">
function calculate() {
var f1=document.x.f1.value;
var f2=document.x.f2.value;
var f3=eval(f1*f2);
document.x.f3.value=f3;
}
</script>

enter a number in the first 2 fields:<br>
<form name="x">
<input type="text" name="f1" value="" onchange="calculate()"><br>
<input type="text" name="f2" value="" onchange="calculate()"><br>
<input type="text" name="f3" value="">
</form>


HTH,
Joseph DeVore
VeloxWeb Technologies



-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Monday, December 17, 2001 9:55 PM
To: CF-Talk
Subject: <CF_recommendation>


All,

Sorry to post this here.  Does anyone know of a
JavaScript lists like CF-Talk?

I'm trying to multiply two form field values and show
the result in a third without a submit action. So when
the curser moves to the third form field, the calulation
is done automatically.

Thanks for the list recommendations in advance.

____________________________________________________________________________
____
Get the mailserver that powers this list at http://www.coolfusion.com
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists


________________________________________________________________________________
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to