J
jd
Try adding an onkeypress handler to quantity field.
-- jeff
-- jeff
I have an Order form. When I change the quantity I go to a script to
calculate anddisplay the Amount = UnitPrice * Quantity
But the Amount only display if I click somewhere else as the Quantity.
How can I display it without clicking ?
============================================
<SCRIPT LANGUAGE="JavaScript">
function compute(form1) {
form1.mt.value=parseFloat(form1.up.value)*parseInt(form1.qt.value);
jd said:Try adding an onkeypress handler to quantity field.
news:comp.lang.javascript said:Where validFloat() and validInt() are routines that check the values -
you can find routines to do that in the archives or at:
<URL: http://www.merlyn.demon.co.uk >
I'd give you a better link to the number validation routines but the
site seems to be down at the moment.
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.