T
Tina
I have a gridview with a template field with a textbox in the ItemTemplate.
In the RowCommand event when the ChgPerson button is hit I handle the event
at follows:
protected void gvAllUsers_RowCommand(object sender,
GridViewCommandEventArgs e)
{
if ((string)e.CommandName.ToLower() == "chgperson")
{
int myRow = int.Parse(e.CommandArgument.ToString());
TextBox mytb =
(TextBox)gvAllUsers.Rows[myRow].Cells[3].Controls[1];
string mystring = mytb.Text;
}
The problem I'm having is that the old value is still in the textbox
eventhough I changed it in the gridview.
Why?
Thanks,
T
In the RowCommand event when the ChgPerson button is hit I handle the event
at follows:
protected void gvAllUsers_RowCommand(object sender,
GridViewCommandEventArgs e)
{
if ((string)e.CommandName.ToLower() == "chgperson")
{
int myRow = int.Parse(e.CommandArgument.ToString());
TextBox mytb =
(TextBox)gvAllUsers.Rows[myRow].Cells[3].Controls[1];
string mystring = mytb.Text;
}
The problem I'm having is that the old value is still in the textbox
eventhough I changed it in the gridview.
Why?
Thanks,
T