public void BindVendorToUpdate() { VendorModel model = client.EditVendorbyID(VendorID, ParlourId); if (model == null) { Response.Write("<script>alert('Sorry!you are not authorized to perform edit on this Branch.');</script>"); } else { VendorID = model.pkiVendorID; txtVendorName.Text = model.VendorName; btnSubmite.Text = "Update"; } }