<script type="text/javascript">
function onmouseover_Item()
{
var AvailablePcs = parseInt(document.getElementById('ctl00_ContentPlaceHolder1_Gridview1_ctl02_LARQ').innerText);
var TotalPcs = parseInt(document.getElementById('ctl00_ContentPlaceHolder1_Gridview1_ctl02_AQ').value);
if (AvailablePcs < TotalPcs)
{
alert('Please Check Actual Received Quantity');
return false;
}
return true
}
</script>
When alert helighets then i need to make AQ textbox empty or 0
Member
399 Points
1101 Posts
how to make my textbox value zero if alert message shows
Nov 01, 2016 09:51 AM|asp.ambur|LINK
Hello
This is my small javascript code
When alert helighets then i need to make AQ textbox empty or 0
How to do so
Participant
1222 Points
371 Posts
Re: how to make my textbox value zero if alert message shows
Nov 01, 2016 11:05 AM|shivigupta31web|LINK
Hi asp.ambur,
Try the following code, you can use document.getElementById('AQ').value="" to reset a textbox value:
Hope this helps.
Stay humble.
Member
399 Points
1101 Posts
Re: how to make my textbox value zero if alert message shows
Nov 01, 2016 11:26 AM|asp.ambur|LINK
thanks and also i want to focus that textbox need one more query
Thanks
Participant
1222 Points
371 Posts
Re: how to make my textbox value zero if alert message shows
Nov 01, 2016 12:25 PM|shivigupta31web|LINK
Hi asp.ambur,
Just use the focus method :
after you reset the value.
Hope this helps.
Stay humble.