Hi Mathale ,
Its not understood that you are looping the code or this execute only once .
If its runs one time then its definitely single entry will inser into database .
Pelase find below code
protected void Button1_Click(object sender, EventArgs e)
{
SaveCustomerInfo();
}
private void SaveCustomerInfo()
{
using (NorthwindDataContext context = new NorthwindDataContext())
{
Customer cust = new Customer();
cust.CustomerID = TextBoxID.Text;
cust.CompanyName = TextBoxCompanyName.Text;
cust.ContactName = TextBoxContactName.Text;
cust.ContactTitle = TextBoxContactTitle.Text;
cust.Address = TextBoxAddress.Text;
cust.City = TextBoxCity.Text;
cust.Region = TextBoxRegion.Text;
cust.PostalCode = TextBoxPostalCode.Text;
cust.Country = TextBoxCountry.Text;
context.Customers.InsertOnSubmit(cust);
context.SubmitChanges();
LiteralMessage.Text = "<p style='color:Green;'>Information Successfully saved!</p>";
}
}