Re: C# .Net Tips & Tricks Hi,
This is the simple way to update single row of record with button in gridview..
GridViewRow gvr;
string gvDataKey;
gvr = GridView1.Rows(e.CommandArgument)
gvDataKey = gvr.Cells(1).Text
sqlStr = "UPDATE tblUser SET uActive = 1 WHERE uPrimaryId = " + gvDataKey + ""
Thanks..
S.Balasubramanian.. |