protected void Page_Load(object sender, EventArgs e)
{
DishCart_DataTable = new DataTable();
DishCart_DataTable.Columns.Add("DishId");
DishCart_DataTable.Columns.Add("ImagePath");
DishCart_DataTable.Columns.Add("DishName");
DishCart_DataTable.Columns.Add("Price");
DishCart_DataTable.Columns.Add("Count");
DishCart_DataTable.Columns.Add("Total");
DishCart_DataTable = (DataTable)Session["DishCart"];
grdCart.DataSource = DishCart_DataTable;
grdCart.DataBind();
if (!IsPostBack)
{
LoadNum();
}
}
button click on ConfirmCart.aspx Page :
protected void btnChceckOut_Click(object sender, EventArgs e)
{
Customer_Det();
SaveOrderHead();
ScriptManager.RegisterStartupScript(Page, Page.GetType(), "err_msg", "alert('Your Order Has been Placed ! Your OrderId : " + ObjPL.OrderCode + "')", true);
grdCart.DataSource = null;
grdCart.DataBind();
Session["DishCart"] = null;
Server.Transfer("Index.aspx");
//Response.Write("<!-- Inject Script Filtered -->");
//this.ClientScript.RegisterClientScriptBlock(this.GetType(), "Close", "window.close()", true);
}
Here only : how should i null the session and i want go back to index.aspx page
Thanks in Advance ,
Karthik.k