Ejemplo n.º 1
0
 void DoSave()
 {
     if (DoValidate())return;
     var bl = new StoreManager
                  {
                      storecode = storecode.Text,
                      storetype = storetype.EditValue.ToString(),
                      storename = storename.Text,
                      address = address.Text,
                      phono = phoneno.Text,
                      fax = fax.Text,
                      communicationtype = int.Parse(radioGroup1.EditValue.ToString()),
                      COMPANY = lookupcompany.EditValue.ToString()
                  };
     var retval = bl.DoSave();
     if(retval=="1")
     {
         storecode.Text = bl.storecode;
         XtraMessageBox.Show("Data saved sucessfully", "POS", MessageBoxButtons.OK, MessageBoxIcon.Information);
         RibbonSaveEnable = false;
         RibbonPageEdit = false;
     }
     else
     {
         XtraMessageBox.Show(retval, "POS", MessageBoxButtons.OK, MessageBoxIcon.Error);
     }
   
 }