private void btnSave_Click(object sender, EventArgs e) { try { if (isValid()) { bindLObj(); if (saveState) { ////Save sample //if (mMasterBLL.saveObj("POS_Brand", mBrandObj)) //{ // MessageBox.Show("Save Completely"); // saveState = false; //} //Save with history if (mMasterBLL.saveObjHis("POS_Brand", mBrandObj)) { MessageBox.Show("Save Completely"); saveState = false; } } else { ////update sample //if (mMasterBLL.updateObj("POS_Brand", mBrandObj)) //{ // MessageBox.Show("update Completely"); //} //update with history if (mMasterBLL.updateObjHis("POS_Brand", mBrandObj)) { MessageBox.Show("update Completely"); } } } } catch (Exception ex) { MessageBox.Show(ex.ToString()); } }