I done some calculation in my aspx page by javascript but after calculation output on textbox is like NaN
NaN error in java-script calculation in asp.net in Mozilla fire-fox
Work fine in google chrome and internet explorer
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Sanjeeb LenkaRank #301 · 8.3K reputationPosted Jun 16, 2013, 8:55 PM EDT
sapana firke158 reputationPosted Jun 16, 2013, 9:10 PM EDT
Riyaz AkhtarRank #2,275 · 619 reputationPosted Jun 16, 2013, 10:53 PM EDT
var str =parseInt( document.getElementById('<%=txtbookingamtbbooking.ClientID %>').value);
Jignesh TrivediRank #16 · 50.3K reputationPosted Jun 16, 2013, 11:57 PM EDT
hi,
there is one function called "isNaN", with the help of this function we can identify whether the value is null or not,
var testString;
var boolTest = isNaN(testString);
Please refer
http://www.w3schools.com/jsref/jsref_isnan.asp
http://msdn.microsoft.com/en-us/library/ie/66ztdbe6(v=vs.94).aspx
hope this will help you.
sapana firke158 reputationPosted Jun 17, 2013, 12:45 AM EDT