Try this..
<asp:TemplateField>
<ItemTemplate>
<asp:LinkButton runat="server" ID="linkmodel" Text='<%#Eval("MenuItem") %>'
CommandArgument='<%#Eval("CommandName") %>'
OnCommand="linkmodel_Click; CommandName="id"
OnClientClick="return confirm('Are You Sure')">
</asp:LinkButton>
</ItemTemplate>
</asp:TemplateField>
In code behind.....
void linkmodel_Click(Object sender, GridViewCommandEventArgs e)
{
if(e.CommandName=="id")
{
int id=e.commandargument.tostring();
}
}
nopte-use proper naming conventation......
I hope it will helpfull 4 u.....