private void treeList1_MouseUp(object sender, MouseEventArgs e) { panelControl1.Controls.Clear(); var tree = (TreeList)sender; var p = new Point(Cursor.Position.X, Cursor.Position.Y); if (e.Button == MouseButtons.Left || treeList1.State == TreeListState.Regular) { var hitInfo = tree.CalcHitInfo(e.Location); if (hitInfo.Node == null) { return; } if (hitInfo.Node.GetValue("FormName") == null || hitInfo.Node.GetValue("FormName") == "") { return; } var formName = hitInfo.Node.GetValue("FormName").ToString(); var form = (Form)Assembly.Load("View_Winform").CreateInstance(formName); if (form == null) { return; } form.AutoScrollMinSize = panelControl1.Size; if (SplashScreenManager.Default != null) { SplashScreenManager.CloseForm(); } SplashScreenManager.ShowForm(typeof(LoadWaitForm)); form.MdiParent = this; form.Parent = this.panelControl1; form.FormBorderStyle = FormBorderStyle.None; form.Dock = DockStyle.Fill; form.Show(); } SplashScreenManager.CloseForm(); }
private void btnSourceFolder_Click(object sender, EventArgs e) { FileList = null; FileList = new List <ImageFile>(); using (var dialouge = new FolderBrowserDialog()) { if (dialouge.ShowDialog() == DialogResult.OK) { SplashScreenManager.ShowForm(this, typeof(ProgressForm), true, true, false); SplashScreenManager.Default.SetWaitFormDescription("Importing..."); txtSourcePath.EditValue = dialouge.SelectedPath; var dInfo = new DirectoryInfo(txtSourcePath.EditValue.ToString()); var fInfo = dInfo.GetFiles("*.jpg", chkIncludeSubFolder.Checked ? SearchOption.AllDirectories : SearchOption.TopDirectoryOnly); var orderedList = fInfo.OrderBy(x => x.CreationTime).ToList(); FileList.AddRange(orderedList.Select(file => new ImageFile { Name = file.Name, Number = file.Name.Substring(0, file.Name.Length - 4), Attributes = file.Attributes, FullPath = file.FullName, Rating = UseRatings ? GetRating(file) : "" })); SplashScreenManager.CloseForm(false); if (FileList.Count > 0) { btnPreview.Visibility = BarItemVisibility.Always; using (var form = new PreviewForm(FileList, UseRatings)) { form.ShowDialog(this); } } } } }
private void MostrarOrdenes() { if (string.IsNullOrEmpty(Convert.ToString(this.Txt_NomClasificador.Value))) { MessageBox.Show("Debe Elegir un Clasificador"); } else { SplashScreenManager.ShowForm(this, typeof(WaitForm1), true, true, false); SplashScreenManager.Default.SetWaitFormDescription("Recopilando informaciòn..."); double dblImporte = Convert.ToDouble(this.Txt_Importe.Value); Service.DataGeneral SDG = new Service.DataGeneral(); if (MyStuff.UsaWCF == true) { DT_Proyecto = objWCF.Lista_Proyecto_SaldoAñoAnterior_Clasificador(strCodCompañia, strCodClasificador, dblImporte, strOrdenesElegidas ).Tables[0]; } else { DT_Proyecto = SDG.Lista_Proyecto_SaldoAñoAnterior_Clasificador(strCodCompañia, strCodClasificador, dblImporte, strOrdenesElegidas ).Tables[0]; } this.Grd_mvto_Mayor_FuenteFinanciamiento.DataSource = DT_Proyecto; if (blnMuestraFormato == true) { blnMuestraFormato = false; this.FormatoGrid(); } this.AdicionaImagenesGrilla(); SplashScreenManager.CloseForm(); } }
private void LoadImages() { gc.Visible = true; gc.Gallery.ItemImageLayout = ImageLayoutMode.ZoomInside; gc.Gallery.ImageSize = new Size(120, 90); gc.Gallery.ShowItemText = true; groupControlSource.Visible = false; groupControlDestination.Visible = false; // UseRatings = chkUseRatings.Checked; var group1 = new GalleryItemGroup { Caption = @"Click on Images to toggle current lock/ ratings." }; gc.Gallery.Groups.Clear(); gc.Gallery.Groups.Add(group1); btnBack.Visibility = BarItemVisibility.Always; btnPreview.Visibility = BarItemVisibility.Never; SplashScreenManager.ShowForm(this, typeof(ProgressForm), true, true, false); SplashScreenManager.Default.SetWaitFormDescription("Loading..."); if (!UseRatings) { foreach (var file in FileList) { var img = Image.FromFile(file.FullPath); group1.Items.Add(new GalleryItem(img, file.Name, GetAttributeString(file.Attributes))); } } else if (UseRatings) { foreach (var file in FileList) { var img = Image.FromFile(file.FullPath); group1.Items.Add(new GalleryItem(img, file.Name, GetRatingString(file.Rating))); } } SplashScreenManager.CloseForm(false); }
public Form1() { SplashScreenManager.ShowForm(this, typeof(WaitForm1), true, true, false); InitializeComponent(); publicStreetGroup = this; setImages(); ToolStripEvent(); Load += OnFormLoad; sbtnFind.Click += SbtnFind_Click; spbAdd.Click += SpbAdd_Click; sbtnSend.Click += SbtnSend_Click; spbRemove.Click += SpbRemove_Click; OnFormLoad(null, null); //temTable.Columns.Add("Check", typeof(Boolean)); temTable.Columns.Add("UTIN", typeof(string)); temTable.Columns.Add("OrganizationName", typeof(string)); tempResult.Columns.Add("UTIN", typeof(string)); tempResult.Columns.Add("IsPrimary", typeof(Boolean)); gridControl2.DataSource = temTable; _Helper = new GridRadioGroupColumnHelper(gridView2); _Helper.SelectedRowChanged += new EventHandler(_Helper_SelectedRowChanged); SplashScreenManager.CloseForm(false); }
private async void Statue_Of_Limitations() { try { SplashScreenManager.ShowForm(this, typeof(WaitForm1), true, true, false); richEditControl2.Text = ""; var dictionary = new Dictionary <string, object>() { { "@Trans", "SELECT_STATUE" }, { "@State_Id", State_Id }, }; var data = new StringContent(JsonConvert.SerializeObject(dictionary), Encoding.UTF8, "application/json"); using (var httpClient = new HttpClient()) { var response = await httpClient.PostAsync(Base_Url.Url + "/OrderInstruction/Statue", data); if (response.IsSuccessStatusCode) { if (response.StatusCode == HttpStatusCode.OK) { var result = await response.Content.ReadAsStringAsync(); DataTable dt = JsonConvert.DeserializeObject <DataTable>(result); if (dt != null && dt.Rows.Count > 0) { richEditControl2.Text = dt.Rows[0]["Statute of limitation"].ToString(); } } } } } catch (Exception ex) { throw ex; } finally { SplashScreenManager.CloseForm(false); } }
private void simpleButtonXem_Click(object sender, EventArgs e) { if (this.dateEditTuNgay.Text == "" || this.dateEditDenNgay.Text == "") { XtraMessageBox.Show("Vui lòng nhập ngày báo cáo! ", "Thông báo", MessageBoxButtons.OK, MessageBoxIcon.Information); return; } if (this.cb_solieu.Text == "") { XtraMessageBox.Show("Vui lòng chọn số liệu! ", "Thông báo", MessageBoxButtons.OK, MessageBoxIcon.Information); return; } SplashScreenManager.ShowForm(this.ParentForm, typeof(WaitForm), true, true, false); try { loadReport(); } finally { SplashScreenManager.CloseForm(false); } }
private void InsertCategory(GridView view, int rowHandle) { string name = view.GetRowCellValue(rowHandle, view.Columns[1]).ToString(); if (name == "") { XtraMessageBox.Show("Tên danh mục không hợp lệ"); return; } if (CategoryBUS.Instance.InsertCategory(name)) { SplashScreenManager.ShowForm(typeof(WaitForm1)); LoadCategory(); SplashScreenManager.CloseForm(); Log.WriteLog("add new Category: " + name); } else { XtraMessageBox.Show("Thêm danh mục thất bại", "Lỗi"); } }
private void simpleButton1_Click(object sender, EventArgs e) { using (var dlg = new OpenFileDialog()) { dlg.Title = "Open Image"; dlg.Filter = "Image Files(*.BMP;*.JPG;*.PNG)|*.BMP;*.JPG;*.PNG"; if (dlg.ShowDialog() == DialogResult.OK) { suspectPictureBox.Image = Image.FromFile(dlg.FileName); Image imgInput = Image.FromFile(dlg.FileName); Graphics gInput = Graphics.FromImage(imgInput); System.Drawing.Imaging.ImageFormat thisFormat = imgInput.RawFormat; SplashScreenManager.ShowForm(this, typeof(LoadingScreen), true, true, false, true); SplashScreenManager.Default.SetWaitFormCaption("Loading image..."); image = ImageTools.ImageToBase64(Image.FromFile(dlg.FileName), thisFormat); SplashScreenManager.CloseForm(); suspectPictureBox.SizeMode = PictureBoxSizeMode.StretchImage; Controls.Add(suspectPictureBox); } } }
private void BuroGuncelleForm_Load(object sender, EventArgs e) { txtSicil.DataBindings.Add("Text", buro, "SicilNo", true, DataSourceUpdateMode.Never); txtTC.DataBindings.Add("Text", buro, "TcKimlikNo", true, DataSourceUpdateMode.Never); txtVergi.DataBindings.Add("Text", buro, "VergiNumarsi", true, DataSourceUpdateMode.Never); txtAd.DataBindings.Add("Text", buro, "AdSoyad", true, DataSourceUpdateMode.Never); txtIl.DataBindings.Add("Text", buro, "KomisyonIl", true, DataSourceUpdateMode.Never); txtIlce.DataBindings.Add("Text", buro, "KomisyonIlce", true, DataSourceUpdateMode.Never); txtSabit.DataBindings.Add("Text", buro.TelefonBilgileri.FirstOrDefault(x => x.SabitCepFax == TelefonTipi.Sabit), "Numara", true, DataSourceUpdateMode.Never); txtCep.DataBindings.Add("Text", buro.TelefonBilgileri.FirstOrDefault(x => x.SabitCepFax == TelefonTipi.Cep), "Numara", true, DataSourceUpdateMode.Never); txtFax.DataBindings.Add("Text", buro.TelefonBilgileri.FirstOrDefault(x => x.SabitCepFax == TelefonTipi.Fax), "Numara", true, DataSourceUpdateMode.Never); txtAdres.DataBindings.Add("Text", buro, "Adres", true, DataSourceUpdateMode.Never); txtEposta.DataBindings.Add("Text", buro, "EPosta", true, DataSourceUpdateMode.Never); foreach (HesapBilgileri hsp in buro.HesapBilgileri) { hesapSource.Add(hsp); } gridControlBanka.RefreshDataSource(); SplashScreenManager.CloseForm(); }
static void Main(string[] args) { CultureInfo culture = CultureInfo.CreateSpecificCulture("en-US"); Thread.CurrentThread.CurrentCulture = culture; Thread.CurrentThread.CurrentUICulture = culture; CultureInfo.DefaultThreadCurrentCulture = culture; CultureInfo.DefaultThreadCurrentUICulture = culture; if (args != null && args.Length > 0) { Settings.IgnoreFileSetting = true; Output.Current.Add($"Command line: {string.Join(" ", args)}"); try { AttachConsole(); var provider = new CmdWorker(CmdParser.Parse(args)); Environment.Exit(provider.FixIndexes()); } catch (Exception ex) { Output.Current.Add(ex.Message); } } else { Application.ThreadException += Application_ThreadException; Application.SetUnhandledExceptionMode(UnhandledExceptionMode.CatchException); Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); UserLookAndFeel.Default.SetSkinStyle("Office 2016 Dark"); SplashScreenManager.ShowForm(typeof(SplashScreenBox)); var mainBox = new MainBox(); SplashScreenManager.CloseForm(); Application.Run(mainBox); } }
private void navBarItem10_LinkClicked(object sender, DevExpress.XtraNavBar.NavBarLinkEventArgs e) { timer2.Start(); if (SplashScreenManager.Default != null && SplashScreenManager.Default.IsSplashFormVisible) { SplashScreenManager.CloseForm(); } SplashScreenManager.ShowForm(typeof(WaitForm1)); if (stat == null) { stat = new statistique(); } else { wait = 1; } etat_stat = "stock"; stat.MdiParent = Form1.ActiveForm; stat.Show(); stat.BringToFront(); }
private void simpleButton1_Click(object sender, EventArgs e) { string solieu = ""; if (this.dateEdit_tungay.Text == "" || this.dateEdit_denngay.Text == "") { XtraMessageBox.Show("Vui lòng nhập ngày báo cáo! ", "Thông báo", MessageBoxButtons.OK, MessageBoxIcon.Information); return; } if (this.cb_solieu.Text == "") { XtraMessageBox.Show("Vui lòng chọn số liệu! ", "Thông báo", MessageBoxButtons.OK, MessageBoxIcon.Information); return; } else { if (this.cb_solieu.Text == "Nội trú") { solieu = "AND solieu=1"; so_lieu_7980 = "=1"; } if (this.cb_solieu.Text == "Ngoại trú") { solieu = "AND solieu!=1"; so_lieu_7980 = "!=1"; } } SplashScreenManager.ShowForm(this.ParentForm, typeof(WaitForm), true, true, false); try { du_lieu_tthuyqt(dateEdit_tungay.Text, dateEdit_denngay.Text, solieu); gridControl1.DataSource = Table_tthuyqt; simpleButton3.Enabled = true; } finally { SplashScreenManager.CloseForm(false); } }
public FrmMinistryApproval() { SplashScreenManager.ShowForm(this, typeof(WaitForm1), true, true, false); InitializeComponent(); publicStreetGroup = this; setImages(); ToolStripEvent(); Load += OnFormLoad; OnFormLoad(null, null); tableTrans.Columns.Add("pPeriod", typeof(string)); tableTrans.Columns.Add("pNarriation", typeof(string)); tableTrans.Columns.Add("pBankAccountID", typeof(int)); tableTrans.Columns.Add("pSummaryID", typeof(int)); tableTrans.Columns.Add("pFinancialperiodID", typeof(int)); tableTrans.Columns.Add("pAgencyCode", typeof(string)); tableTrans.Columns.Add("pRevenueCode", typeof(string)); tableTrans.Columns.Add("pDESCRIPTION", typeof(string)); tableTrans.Columns.Add("pAgencyName", typeof(string)); tableTrans.Columns.Add("pAmount", typeof(decimal)); SplashScreenManager.CloseForm(false); }
public static HttpResponseMessage call(string url , string type ="get", string content="", bool checkToken=true, bool autoGetToken=true, bool showWaiting = true) { string error = ""; if (showWaiting) { SplashScreenManager.ShowForm(currentForm, typeof(WaitForm1), true, true, false); SplashScreenManager.Default.SetWaitFormCaption("Please wait"); SplashScreenManager.Default.SetWaitFormDescription("System is loading data"); } if (!ServerCertificate) { ServicePointManager.ServerCertificateValidationCallback += (sender, certificate, chain, sslPolicyErrors) => true; ServerCertificate = true; } HttpResponseMessage res = new HttpResponseMessage(); res.StatusCode = System.Net.HttpStatusCode.InternalServerError; HttpClient client = new HttpClient(); try { url = url.Replace("%", "%25"); client.BaseAddress = new Uri(urlHost); client.DefaultRequestHeaders.Accept.Add(new MediaTypeWithQualityHeaderValue("application/json"); if (checkToken) { DateTime now = DateTime.Now; } } catch (Exception ex) { if (showWaiting) { SplashScreenManager.CloseForm(); MessageBox.Show("Can not connect to Server, please check your connection. Thank you"); return res; } } }
private static void startApplication() { changeUser = false; LoginForm lf = new LoginForm(); SplashScreenManager.CloseForm(false); DialogResult rs = lf.ShowDialog(); if (rs == DialogResult.OK) { DesktopForm desk = new DesktopForm(); desk.ShowDialog(); } else { Exit(0); } if (changeUser) { startApplication(); } }
private void navBarItem20_LinkClicked(object sender, DevExpress.XtraNavBar.NavBarLinkEventArgs e) { timer2.Start(); if (SplashScreenManager.Default != null && SplashScreenManager.Default.IsSplashFormVisible) { SplashScreenManager.CloseForm(); } SplashScreenManager.ShowForm(typeof(WaitForm1)); if (list_dev == null) { list_dev = new liste_devis(); } else { wait = 1; } list_dev.MdiParent = Form1.ActiveForm; list_dev.Show(); list_dev.BringToFront(); }
private void barButtonItemSave_ItemClick(object sender, ItemClickEventArgs e) { Extensions.Extensions.ShowWaitForm(description: "Departman kaydediliyor..."); DepartmentSolClient client = Extensions.Extensions.getDepartmentSolClient(); if (client == null) { return; } if (_department == null) { _department = new Department { Name = textEditName.Text, IsActive = checkEditIsActive.Checked, MinAge = textEditMin.Text.ToNullableInt32(), MaxAge = Text.ToNullableInt32(), Gender = lookUpEditGender.EditValue as bool? }; } else { _department.Name = textEditName.Text; _department.IsActive = checkEditIsActive.Checked; _department.MinAge = textEditMin.Text.ToNullableInt32(); _department.MaxAge = textEditMax.Text.ToNullableInt32(); _department.Gender = lookUpEditGender.EditValue as bool?; } ProcessResult processResult = update ? client.Update(_department) : client.Insert(_department); SplashScreenManager.CloseForm(false); Extensions.Extensions.ProcessResultMessage(processResult.Errors, (int)processResult.Result); if (processResult.Result == ExtensionsBLLResult.Success) { Close(); } }
private void navBarItem12_LinkClicked_1(object sender, DevExpress.XtraNavBar.NavBarLinkEventArgs e) { timer2.Start(); if (SplashScreenManager.Default != null && SplashScreenManager.Default.IsSplashFormVisible) { SplashScreenManager.CloseForm(); } SplashScreenManager.ShowForm(typeof(WaitForm1)); if (cdeeee == null) { cdeeee = new cde_recu(); } else { wait = 1; } cdeeee.MdiParent = Form1.ActiveForm; cdeeee.Show(); cdeeee.BringToFront(); }
private void barButtonItemSave_ItemClick(object sender, ItemClickEventArgs e) { Rendezvous rendezvous = new Rendezvous(); rendezvous.Date = DateTime.Today; rendezvous.RendezvousTimeId = bindingSourceTimes.Current.IsNull() ? 0 : (bindingSourceTimes.Current as RendezvousTime).Id; rendezvous.PatientId = patient.IsNull() ? 0 : patient.Id; rendezvous.DoctorId = (int)(lookUpEditDoctor.EditValue.IsNull() ? 0 : lookUpEditDoctor.EditValue); Extensions.Extensions.ShowWaitForm(description: "Randevu kaydediliyor..."); RendezvousSolClient client = Extensions.Extensions.GetRendezvousService(); result = client.Insert(rendezvous, true); SplashScreenManager.CloseForm(false); Extensions.Extensions.ProcessResultMessage(result.Errors.ToArray(), (int)result.Result); if (result.Result == ExtensionsBLLResult.Success) { Close(); } }
public OnatDeUnidadArtistica_XtraReport(int agrupacionId, DateTime fechaFinal, DateTime fechaInicial, int tipoMonedaId) { try { SplashScreenManager.ShowForm(typeof(ReportesWaitForm)); } catch { SplashScreenManager.CloseForm(); SplashScreenManager.ShowForm(typeof(ReportesWaitForm)); } InitializeComponent(); bindingSource1.DataSource = Agrupacion.GetOnatDeUnidadArtistica(agrupacionId, fechaFinal, fechaInicial, tipoMonedaId); var GlobalDataContext = new NegocioDataContext(); Configuracion_linqServerModeSource.QueryableSource = GlobalDataContext.ConfiguracionGeneral; ConfiguracionGeneral configuracion = GlobalDataContext.ConfiguracionGeneral.FirstOrDefault(); if (configuracion.LogoAgencia != null) { MemoryStream ms = new MemoryStream(configuracion.LogoAgencia); Bitmap imagenBitmap = new Bitmap(ms); xrPictureBox1.Image = imagenBitmap; } Titulo_xrRichText.Html = $"<center>Ingreso de unidad artística <br> Agrupacion: <b>{Agrupacion.GetAgrupacionById(agrupacionId).Nombre.ToUpper()}</b> <br> Período <b>{fechaInicial.ToShortDateString()} - {fechaFinal.ToShortDateString()}</b> <br> Moneda: <b>{TipoMoneda.GetMonedaById(tipoMonedaId).Abreviatura}</b></center>"; Titulo_xrRichText.TextAlignment = TextAlignment.MiddleCenter; ExportOptions.Xls.SheetName = $"Onat {Agrupacion.GetAgrupacionById(agrupacionId).Nombre} {TipoMoneda.GetMonedaById(tipoMonedaId).Abreviatura}"; ExportOptions.Xlsx.SheetName = $"Onat {Agrupacion.GetAgrupacionById(agrupacionId).Nombre} {TipoMoneda.GetMonedaById(tipoMonedaId).Abreviatura}"; string[] lineas = new string[4]; lineas[0] = $"Dirección: {configuracion.DireccionEmpresa}"; lineas[1] = $"Tel: {configuracion.TelefonosAgencia}"; lineas[2] = $"Correo electrónico: {configuracion.CorreoElectronico} "; lineas[3] = $"Web: {configuracion.SitioWeb}"; DatosContactoxrRichText.Lines = lineas; }
private void Efficiency_Summary_Load(object sender, EventArgs e) { try { SplashScreenManager.ShowForm(this, typeof(Masters.WaitForm1), true, true, false); WindowState = FormWindowState.Maximized; checkEditCustomize.Checked = false; dbc.BindMonth(lookUpEditMonth); dbc.BindYear(lookUpEditYear); lookUpEditMonth.EditValue = DateTime.Now.Month; lookUpEditYear.EditValue = DateTime.Now.Year; } catch (Exception ex) { SplashScreenManager.CloseForm(false); XtraMessageBox.Show("Something went wrong check with admin"); } finally { SplashScreenManager.CloseForm(false); } }
/// <summary> /// Обновить схему БД. /// </summary> public static void UpdateSchema() { try { SplashScreenManager.ShowForm(null, typeof(WaitFormEx), true, true, false); SplashScreenManager.Default.SetWaitFormDescription("Обновляется схема базы данных..."); XpoDefault.Session.UpdateSchema(); SplashScreenManager.CloseForm(false); } catch (Exception ex) { SplashScreenManager.CloseForm(false); XtraMessageBox.Show( ex.Message, ex.Source, MessageBoxButtons.OK, MessageBoxIcon.Warning, MessageBoxDefaultButton.Button1); } }
void Init() { SplashScreenManager.ShowForm(this, typeof(WaitForm1), true, true, false); publicStreetGroup = this; setImages(); ToolStripEvent(); Load += OnFormLoad; OnFormLoad(null, null); //RepositoryItemCheck.EndInit(); //RepositoryItemCheckColl.EndInit(); //gridView1.CellValueChanged += GridView1_CellValueChanged; SplashScreenManager.CloseForm(false); }
private void btnRemove_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e) { string id = gvCategory.GetRowCellValue(gvCategory.FocusedRowHandle, gvCategory.Columns[0]).ToString(); string name = gvCategory.GetRowCellValue(gvCategory.FocusedRowHandle, gvCategory.Columns[1]).ToString(); if (XtraMessageBox.Show("Xóa danh mục " + name + "?", "Xác nhận", MessageBoxButtons.YesNo) == DialogResult.Yes) { if (CategoryBUS.Instance.DeteleCategory(int.Parse(id))) { SplashScreenManager.ShowForm(typeof(WaitForm1)); LoadCategory(); SplashScreenManager.CloseForm(); XtraMessageBox.Show("Xóa danh mục thành công", "Thông báo"); Log.WriteLog("delete Category: " + name); } else { XtraMessageBox.Show("Xóa danh mục thất bại\nDanh mục được xóa phải rỗng", "Lỗi"); } } btnRemove.Enabled = false; }
private void ExportOrderHistory() { try { SplashScreenManager.ShowForm(this, typeof(Masters.WaitForm1), true, true, false); PrintingSystem ps = new PrintingSystem(); CompositeLink compositeLink = new CompositeLink(ps); PrintableComponentLink LinkOrderhistory = new PrintableComponentLink(); LinkOrderhistory.Component = gridControlOrderHistory; PrintableComponentLink LinkOrderStatusHistory = new PrintableComponentLink(); LinkOrderStatusHistory.Component = gridControlOrderStatusHistory; ps.SetCommandVisibility(PrintingSystemCommand.Open, CommandVisibility.All); ps.SetCommandVisibility(new PrintingSystemCommand[] { PrintingSystemCommand.ExportCsv, PrintingSystemCommand.ExportTxt, PrintingSystemCommand.ExportXlsx, PrintingSystemCommand.ExportDocx, PrintingSystemCommand.ExportXls }, CommandVisibility.All); compositeLink.Links.AddRange(new object[] { LinkOrderhistory, LinkOrderStatusHistory }); string ReportName = "Order History"; string folderPath = "C:\\Temp\\"; string Path1 = folderPath + DateTime.Now.ToString("dd-MM-yyyy-hh-mm-ss") + "-" + ReportName + ".xlsx"; compositeLink.CreatePageForEachLink(); ps.XlSheetCreated += PrintingSystem_XlSheetCreated; compositeLink.PrintingSystem.ExportToXlsx(Path1, new XlsxExportOptions() { ExportMode = XlsxExportMode.SingleFilePageByPage, ExportHyperlinks = false, TextExportMode = TextExportMode.Value, IgnoreErrors = XlIgnoreErrors.NumberStoredAsText }); System.Diagnostics.Process.Start(Path1); } catch (Exception e) { throw e; } finally { SplashScreenManager.CloseForm(false); } }
private void txt_Email_address_Properties_Leave(object sender, EventArgs e) { Regex RegExForEmail = new Regex("^([0-9a-zA-Z]([-\\.\\w]*[0-9a-zA-Z])*@([0-9a-zA-Z][-\\w]*[0-9a-zA-Z]\\.)+[a-zA-Z]{2,9})$"); if (txt_Email_address.Text == "") { SplashScreenManager.CloseForm(false); Txt_EmailAddress(); XtraMessageBox.Show("Enter Email_Address"); txt_Email_address.Focus(); return; } else if (RegExForEmail.IsMatch(txt_Email_address.Text)) { } else { SplashScreenManager.CloseForm(false); XtraMessageBox.Show("Email Address Not Valid"); txt_Email_address.Focus(); } }
private async void BindStatusPermissionHistory() { try { SplashScreenManager.ShowForm(this, typeof(WaitForm1), true, true, false); var dictionary = new Dictionary <string, object>() { { "@Trans", "SELECT" }, { "@Order_Id", orderId } }; var data = new StringContent(JsonConvert.SerializeObject(dictionary), Encoding.UTF8, "application/json"); using (var httpClient = new HttpClient()) { var response2 = await httpClient.PostAsync(Base_Url.Url + "/OrderHistory/BindOrderStatusPermission", data); if (response2.IsSuccessStatusCode) { if (response2.StatusCode == HttpStatusCode.OK) { var result1 = await response2.Content.ReadAsStringAsync(); DataTable dt = JsonConvert.DeserializeObject <DataTable>(result1); if (dt.Rows.Count > 0) { gridControlOrderStatusPermissionHistory.DataSource = dt; } } } } } catch (Exception ex) { throw ex; } finally { SplashScreenManager.CloseForm(false); } }
private void nav_retour_clt_LinkClicked(object sender, DevExpress.XtraNavBar.NavBarLinkEventArgs e) { timer2.Start(); if (SplashScreenManager.Default != null && SplashScreenManager.Default.IsSplashFormVisible) { SplashScreenManager.CloseForm(); } SplashScreenManager.ShowForm(typeof(WaitForm1)); if (rttt == null) { rttt = new retour_client(); } else { wait = 1; } rttt.MdiParent = Form1.ActiveForm; rttt.Show(); rttt.BringToFront(); }
private void gridView1_RowCellClick(object sender, RowCellClickEventArgs e) { try { SplashScreenManager.ShowForm(this, typeof(WaitForm1), true, true, false); if (e.Column.FieldName == "Sub_ProcessName") { btn_Submit.Text = "Update"; ddl_Client_Names.Enabled = false; checkedListBox_Subclients.Enabled = false; GridView view = gridControl_client_details.MainView as GridView; var index = view.GetDataRow(view.GetSelectedRows()[0]); ddl_Client_Names.EditValue = index.ItemArray[4]; int _client = Convert.ToInt32(ddl_Client_Names.EditValue); Bind_Sub_Clients1(_client); Selected_Sub_Client = Convert.ToInt32(index.ItemArray[5]); int PT = Convert.ToInt32(index.ItemArray[6]); int DT = Convert.ToInt32(index.ItemArray[7]); checkedListBox_Subclients.SelectedValue = Selected_Sub_Client; checkedListBox_ProjectType.SelectedValue = PT; checkedListBox_DeptType.SelectedValue = DT; } _subclient = checkedListBox_Subclients.SelectedIndex; _Projecttype = checkedListBox_ProjectType.SelectedIndex; _departmenttype = checkedListBox_DeptType.SelectedIndex; checkedListBox_Subclients.SetItemChecked(_subclient, true); checkedListBox_ProjectType.SetItemChecked(_Projecttype, true); checkedListBox_DeptType.SetItemChecked(_departmenttype, true); } catch (Exception ex) { SplashScreenManager.CloseForm(false); throw ex; } finally { SplashScreenManager.CloseForm(false); } }