Hello Lee,
The onblur works great to stop NaN from being seen. I've changed the code to:
cell.innerHTML = '<input type="text" class="field100" style="text-align:right" onblur="ss_keyhandler(event)" onclick="calcactivity(this)" size="5" maxlength="5">';
The only problem is that the user must...
Thanks for the quick reply. So if I understand correctly, I should keep my keyhandler the way it is and simply return when "-" is pressed, and I should modify my code where the totals are calculated.
For more info, here is more of the code. addactivity() is called from onclick in a php file...
Hello,
I am new to Javascript and cannot find anything to help me with this issue. I have a table (4 rows by 7 columns initially) where the user needs to input numbers in col 1 and col 3. The total of these two columns is stored in col 5. My problem is, negative numbers are accepted values but...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.