SCRIPT5009: 'DefaultButtonKeyPress' is undefined issue in IE

Posted by Sahoo under ASP.NET on 8/7/2012 | Points: 10 | Views : 2408 | Status : [Member] | Replies : 1
Hi

I am getting follwoing script in IE only " SCRIPT5009: 'DefaultButtonKeyPress' is undefined " when pressing any key
My code is like
<asp:Literal ID="lblUserName" runat="server"
Text="UserName" /></label>
<asp:TextBox ID="txtUserName" runat="server" />
<asp:RequiredFieldValidator ID="rfvEmail" runat="server" ControlToValidate="txtUserName"
ErrorMessage="UserName Required" Display="Dynamic" Text="*" SetFocusOnError="True" />


When it run in IE it get converted into
<label>UserName</label>
<input name="txtUserName" type="text" value="ex@ex.com" id="txtUserName" onkeydown="DefaultButtonKeyPress(event, 'btnLogin')" />
<span id="rfvEmail" style="color:Red;display:none;">*</span>


What is the reason of script error ?


Thanks in advance




Responses

Posted by: Vuyiswamb on: 8/7/2012 [Member] [MVP] [Administrator] NotApplicable | Points: 25

Up
0
Down
Do you have a JQuery Code that assign an Event to this textbox ?

Where is the definition of a Javascript function "DefaultButtonKeyPress" ?

Thank you for posting at Dotnetfunda
[Administrator]

Sahoo, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response