Click here to Skip to main content
15,917,060 members
Please Sign up or sign in to vote.
2.57/5 (3 votes)
See more:
VB
Error   2   'ASP.default_aspx' does not contain a definition for 'gvEmployee_RowEditing' and no extension method 'gvEmployee_RowEditing' accepting a first argument of type 'ASP.default_aspx' could be found (are you missing a using directive or an assembly reference?) C:\Users\Ashwini\Desktop\WebSite6\Default.aspx  11

Warning 1 Validation (ASP.Net): Element 'asp:Calendar' is missing required attribute 'runat'. C:\Users\Ashwini\Desktop\WebSite6\Default.aspx 32 26 WebSite6
Posted
Comments
joshrduncan2012 22-Jan-14 9:37am    
Where is your code? Show us your code that this error is pointing to.

In Your ASPX page for the gridview you have mapped the event gvEmployee_RowEditing for OnRowEditing

The event method is missing in the code behind file (aspx.cs).

Try to add a new event for gvEmployee_RowEditing or map to the desired event in the code behind...

To fix this issue,Add this in your code behind.cs

C#
protected void gvEmployee_RowEditing(object sender, GridViewEditEventArgs e)
       {
           // your coding here..
       }
 
Share this answer
 
v2
Comments
ashwini dharamsale 22-Jan-14 9:42am    
protected void gvTechnision_RowEditing(object sender, GridViewEditEventArgs e)
{
gvTechnision.EditIndex = e.NewEditIndex;
BindGrid();
}
Karthik_Mahalingam 22-Jan-14 9:44am    
use this...
<asp:GridView ID="gvTechnision" runat="server" AutoGenerateColumns="false" ShowFooter="true"
Style="margin-left: 113px" Width="1049px"
OnRowCommand="gvTechnision_OnRowCommand"
OnRowCancelingEdit="gvTechnision_RowCancelingEdit"
OnRowDeleting="gvTechnision_RowDeleting" OnRowEditing="gvTechnision_RowEditing"
OnRowUpdating="gvTechnision_RowUpdating"
OnPageIndexChanging="gvTechnision_PageIndexChanging">
BindGrid();
}
ashwini dharamsale 22-Jan-14 9:45am    
Unable to cast object of type 'System.Web.UI.WebControls.Calendar' to type 'System.Web.UI.WebControls.TextBox'.
Karthik_Mahalingam 22-Jan-14 9:49am    
Warning 1 Validation (ASP.Net): Element 'asp:Calendar' is missing required attribute 'runat'. C:\Users\Ashwini\Desktop\WebSite6\Default.aspx 32 26 WebSite6
Karthik_Mahalingam 22-Jan-14 9:49am    
Add runat=server to the calendar tag.
VB
<asp:GridView ID="gvTechnision" runat="server" AutoGenerateColumns="false" ShowFooter="true"
           Style="margin-left: 113px" Width="1049px"
           OnRowCommand="gvTechnision_OnRowCommand"
           OnRowCancelingEdit="gvTechnision_RowCancelingEdit"
           OnRowDeleting="gvTechnision_RowDeleting" OnRowEditing="gvEmployee_RowEditing"
           OnRowUpdating="gvTechnision_RowUpdating"
           OnPageIndexChanging="gvTechnision_PageIndexChanging">
 
Share this answer
 
Comments
Vamsi Krishnna 22-Jan-14 9:44am    
Can u also post your code file or .cs file for the current page??
Does it contain any method as "gvEmployee_RowEditing"????
for date in gridview how we has to give in asp.net and in c# for inserting the data in database
 
Share this answer
 
Comments
Karthik_Mahalingam 22-Jan-14 9:48am    
Please dont add comments in Solution Part.. you can use Have a Question or Comment? button.
still its gtting same error
Unable to cast object of type 'System.Web.UI.WebControls.Calendar' to type 'System.Web.UI.WebControls.TextBox'.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900