private void bbiSave_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e) { if (MsgDlg.Show("هل انت متأكد ؟", MsgDlg.MessageType.Question) == DialogResult.No) { return; } DevExpress.Xpo.AsyncCommitCallback CommitCallBack = (o) => { SplashScreenManager.CloseForm(); if (o == null) { MsgDlg.ShowAlert(Properties.Settings.Default.msg_SaveSuccess, MsgDlg.MessageType.Success, (Form)Parent.Parent.Parent); Logger.Info(Properties.Settings.Default.msg_SaveSuccess); } else { MsgDlg.ShowAlert(String.Format("{0}, {1}, {2}", Properties.Settings.Default.msg_SavingFailed, Environment.NewLine, o.Message), MsgDlg.MessageType.Error, (Form)Parent.Parent.Parent); Classes.Core.LogException(Logger, o.InnerException, Classes.Core.ExceptionLevelEnum.General, Classes.Managers.UserManager.defaultInstance.User.UserId); } }; SplashScreenManager.ShowForm(typeof(FixedAssets.Views.Main.WaitWindowFrm)); SplashScreenManager.Default.SetWaitFormDescription(Properties.Settings.Default.msg_SavingInProgress); UOW.CommitTransactionAsync(CommitCallBack); }