Esempio n. 1
0
        private void toolStripButtonEdit_Click(object sender, EventArgs e)
        {
            if (enforceLawGridViewCompanyFireworks.SelectedRows.Count == 0)
                return;

            if (enforceLawGridViewCompanyFireworks.SelectedRows[0].Tag == null)
                return;

            UseWaitCursor = true;
            Application.DoEvents();

            try
            {
                CompanyFireworks CompanyFireworks = enforceLawGridViewCompanyFireworks.SelectedRows[0].Tag as CompanyFireworks;
                CompanyFireworks.Company = (Company)InvokeUtil.SystemService.EntityInit(new Company { CompanyID = CompanyFireworks.CompanyID });
                frmCompanyFirework frm = new frmCompanyFirework(CompanyFireworks);
                frm.OpenWindow(this);
            }
            catch (Exception ex)
            {
                CommonInvoke.ErrorMessageBox(ex);
            }

            UseWaitCursor = false;
        }
Esempio n. 2
0
        private void toolStripButtonAdd_Click(object sender, EventArgs e)
        {
            UseWaitCursor = true;
            Application.DoEvents();

            try
            {
                frmCompanyFirework frm = new frmCompanyFirework();
                frm.OpenWindow(this);
            }
            catch (Exception ex)
            {
                CommonInvoke.ErrorMessageBox(ex);
            }

            UseWaitCursor = false;
        }