Dear Friend
Instead of using document.forms(0).abcd.value
use
document.getElementById('myText').value;
as it will give you more precise result
you can also assign the value returned by the function to a variable and perform operation on it
eg:-
var DivValue=document.getElementById('DivValue');
alert(DivValue);
Regards
Vipin Kumar Mallaya