M
mary
Hi Everyone...Can somebody help me figure out how to fix this error?
I'm out of ideas! Thanks!
CS0123: Method 'IC.Reports.Comp.webic_first.EmpLink_ItemCommand(object,
System.Web.UI.WebControls.CommandEventArgs)' does not match delegate
'void System.EventHandler(object, System.EventArgs)'
In my ASCX page, I have:
<asp:TemplateColumn HeaderText="theID">
<ItemTemplate>
<asp:linkbutton id="EmpLink" OnClick="EmpLink_ItemCommand"
CommandArgument='<%# DataBinder.Eval(Container.DataItem, "the_nbr")
%>' runat="server" Text='<%# DataBinder.Eval(Container.DataItem,
"the_nbr") %>' CommandName="select" />
</ItemTemplate>
</asp:TemplateColumn>
And the backend I have:
protected void EmpLink_ItemCommand(object sender,
System.Web.UI.WebControls.CommandEventArgs e)
{
string cmd = e.CommandName;
if (cmd == "select")
{
int m_empnbr= 0;
m_empnbr = Convert.ToInt32(e.CommandArgument);
GetInfo(m_empnbr);
}
}
I'm out of ideas! Thanks!
CS0123: Method 'IC.Reports.Comp.webic_first.EmpLink_ItemCommand(object,
System.Web.UI.WebControls.CommandEventArgs)' does not match delegate
'void System.EventHandler(object, System.EventArgs)'
In my ASCX page, I have:
<asp:TemplateColumn HeaderText="theID">
<ItemTemplate>
<asp:linkbutton id="EmpLink" OnClick="EmpLink_ItemCommand"
CommandArgument='<%# DataBinder.Eval(Container.DataItem, "the_nbr")
%>' runat="server" Text='<%# DataBinder.Eval(Container.DataItem,
"the_nbr") %>' CommandName="select" />
</ItemTemplate>
</asp:TemplateColumn>
And the backend I have:
protected void EmpLink_ItemCommand(object sender,
System.Web.UI.WebControls.CommandEventArgs e)
{
string cmd = e.CommandName;
if (cmd == "select")
{
int m_empnbr= 0;
m_empnbr = Convert.ToInt32(e.CommandArgument);
GetInfo(m_empnbr);
}
}