onblur issue

Results 1 to 2 of 2

Thread: onblur issue

  1. #1
    Join Date
    Dec 1969

    Default onblur issue

    Hello,<BR><BR>I am using this function onblur of the textbox. But am not able to find the problem why the alertbox is going on<BR>endless loop. <BR><BR>Onblur I need to see if the value entered is a number or not and at the same time I shouldn&#039;t allow the user to enter<BR>null values.<BR><BR>Appreciate if you can help me out,<BR><BR><BR><BR>function stripvals(totval)<BR> {<BR> tval=totval.value;<BR> <BR> tval= parseFloat( tval.replace( /[,$s]/g, "" ) ); <BR> if ( isNaN( tval ) ) tval = 0; <BR> if(totval.value==&#039;&#039;)<BR> {<BR> alert("Please enter a value")<BR> totval.focus()<BR> return false;<BR> <BR> }<BR> <BR> totval.value=tval<BR> }

  2. #2
    Join Date
    Dec 1969

    Default Try using onChange instead...

    I remember running into something like this with onBlur in the past.<BR><BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts