Tech
Forums
Jobs
Books
Events
Live
Interviews Prep
More
Learn
Training
Career
Members
Videos
News
Blogs
Login
Sign Up
Ask Question
1
Reply
a gridview row databound value change
Deepak jena
Apr 11 2017 6:59 AM
185
Reply
in agridview row databound if aquantity value 2.when we add a new row the previous quantity valuealso return 1 .but i want this textbox value assign with previous value 2.plz give the solution.here i have written code.
if (e.Row.RowType == DataControlRowType.DataRow)
{
int i = 1;
TextBox t = (TextBox)e.Row.FindControl("txtquantity");
t.Text = Convert.ToString(i);
Session["quantity"] = t.Text;
txttotalitem.Text = t.Text;
Session["quantity"] = GridView1.Rows.Count;
i want only row which added newly his value will 1 but previous row value means old row value remain unchanged.
Attachment:
Capture12.rar
Upload Source Code
Select only zip and rar file.
Post
Reset
Cancel
Answers (
1
)
Next Recommended Forum
How to cal Web API in Asp.Net Code Behind Page ?
Is it possible to retrieve and show view name dynamicallyMVC