using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;
namespace CURD_Temptable
{
public partial class WebForm1 : System.Web.UI.Page
{
DataTable dtOrderList;
DataRow drOrderList = null;
protected void Page_Load(object sender, EventArgs e)
{
//CreateTable();
if(!IsPostBack)
Bindgridview();
}
private void Bindgridview()
{
if (ViewState["Table"] == null)
CreateTable();
else
dtOrderList = (DataTable)ViewState["Table"];
//if (dtOrderList.Rows.Count > 0)
//{
GridView1.DataSource = dtOrderList;
GridView1.DataBind();
//}
}
private DataTable BindProducts()
{
DataTable table = new DataTable();
table.Columns.Add("ProductId", typeof(int));
table.Columns.Add("ProductName&quo ...
Go to the complete details ...