Click here to Skip to main content
16,006,531 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
i am using 3-tier architecture. in that i have a content page naming orderHeader, in that i want to add tabcontroller with page naming orderLine. my querry is that the button should be use on the oderLine page should be used to store the data of the oderHeader page so the coding of both the page will be done on a single button so where should i keep the button? where should i do the coding, on the .cs page of orderHeaderPage or on .cs page of orderLine page.

What I have tried:

protected void Button1_Click(object sender, EventArgs e)
{
BCommon.orderLine objorder1 = new BCommon.orderLine();
//objorder1.Orderno = TextBox13.Text;
objorder1.Sno = oltxtSno.Text;
objorder1.Item =olDDLItem.Text;
objorder1.Descriptions = oltxtDescription.Text;
objorder1.Quantity = oltxtquantity.Text;
objorder1.Unit =oltxtUnit.Text;
objorder1.Fabrication = oltxtFabrication.Text;
objorder1.Add = oltxtAdd.Text;
objorder1.Price = oltxtPrice.Text;
objorder1.Discount = oltxtDiscount.Text;
objorder1.DiscountAmount = oltxtDiscountAmt.Text;
objorder1.Amount = oltxtAmt.Text;
objorder1.PlannedDeliveryDate = oltxtPlannedDeliveryDt.Text;

BussinessLogic.bl_orderLine b1 = new BussinessLogic.bl_orderLine();
string result = b1.submit(objorder1);

try
{

//result = BussinessLogic.Bl_customerMaster.
if (result != null)
{
olResult.Text = "data inserted";
}
else
{
olResult.Text = "data is not inserted";
}
}
finally
{
objorder1 = null;
b1 = null;
}

// TextBox13.Text = string.Empty;
oltxtSno.Text = string.Empty;
olDDLItem.Text = string.Empty;
oltxtDescription.Text = string.Empty;
oltxtquantity.Text = string.Empty;
oltxtUnit.Text = string.Empty;
oltxtFabrication.Text = string.Empty;
oltxtAdd.Text = string.Empty;
oltxtPrice.Text = string.Empty;
oltxtDiscount.Text = string.Empty;
oltxtDiscountAmt.Text = string.Empty;
oltxtAmt.Text = string.Empty;
olPlannedDelivery.Text = string.Empty;
}

have these type of coding for button so where should i keep the button? and code on the .cs???
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900