示例#1
0
        public void PleaseAttachHWGR()
        {
            FormAttachHwgr form = new FormAttachHwgr();

            form.Bind(m_world);

            try
            {
                if (form.ShowDialog() == DialogResult.OK)
                {
                    hwgrs.Add(new ViceHWGR(form.EntityName,
                                           form.Attached.ID,
                                           (DateTime)form.Attached.BeginTime,
                                           (DateTime)form.Attached.EndTime,
                                           form.Attached.HWGR_ID));
                }
            }
            catch (EntityException ex)
            {
                XtraMessageBox.Show(ex.Message, ex.GetType().ToString(), MessageBoxButtons.OK, MessageBoxIcon.Error);
            }
        }
示例#2
0
        public void PleaseAttachHWGR()
        {
            FormAttachHwgr form = new FormAttachHwgr();
            form.Bind(m_world);

            try
            {
                if (form.ShowDialog() == DialogResult.OK)
                    hwgrs.Add (new ViceHWGR (form.EntityName,
                        form.Attached.ID,
                        (DateTime)form.Attached.BeginTime,
                        (DateTime)form.Attached.EndTime,
                        form.Attached.HWGR_ID));
            }        
            catch (EntityException ex)
            {
                XtraMessageBox.Show(ex.Message, ex.GetType().ToString(), MessageBoxButtons.OK, MessageBoxIcon.Error);
            }
        }