Recalculating Column Values in DataGrid
Details Related Types
Site:  DotNetJunkies
Original URL:  http://www.dotnetjunkies.com/tutorials.aspx?tutorialid=334
Summary:
"I have bound a grid which contains three template cols (A, B ,C). Each Column contains a TextBox. When I bind the data I get the value of these grid TextBoxes from SQL Server. Now all that I am trying to do is when I change the value of either column A or B (TextBoxes) I want to recalculate column C. Can you please help me?" In some cases you need to dynamically calculate the value of a DataGrid column based on values in other columns. This article will explain how to make this happen.
System.Data.DataSet
System.Data.SqlClient.SqlConnection
System.Data.SqlClient.SqlDataAdapter
System.EventArgs
System.Web.UI.WebControls.BorderStyle
System.Web.UI.WebControls.DataGrid
System.Web.UI.WebControls.DataGridCommandEventArgs
System.Web.UI.WebControls.DataGridItemEventArgs
System.Web.UI.WebControls.HorizontalAlign
System.Web.UI.WebControls.TemplateColumn
System.Web.UI.WebControls.TextBox
Ad
MBR BootFX
Best-of-breed application framework for .NET projects, developed by Matthew Baxter-Reynolds and MBR IT
 
 Copyright © Matthew Baxter-Reynolds 2001-2008. '.NET 247 Software Development Services' is a trading style of MBR IT Solutions Ltd.
Contact Us - Terms of Use - Privacy Policy - www.dotnet247.com