private void CoachBrowser_Load(object sender, EventArgs e) { if (!this.DesignMode) { IDCardConfig config = FT.Commons.Cache.StaticCacheManager.GetConfig<IDCardConfig>(); if(config.UseIDCard) reader = new IDCardReaderHelper(new De_ReadICCardComplete(this.AfterReadIdCard)); } }
private void StudentBrowser_Load(object sender, EventArgs e) { if (!this.DesignMode) { IDCardConfig config = FT.Commons.Cache.StaticCacheManager.GetConfig<IDCardConfig>(); if (config.UseIDCard) reader = new IDCardReaderHelper(new De_ReadICCardComplete(AfterReadIdCard)); AllPrinterConfig printconfig = AllPrinterConfig.GetPrinterConfig(); if (printconfig.SysConfig.DefaultEye!=null&&printconfig.SysConfig.DefaultEye.Length != 0) { try { this.txtLeftEye.Text = this.txtRightEye.Text = printconfig.SysConfig.DefaultEye; } catch (System.Exception exe) { } } this.txtDescription.KeyDown -= new KeyEventHandler(FormHelper.EnterToTab); this.InitAllAddress(); } }
private void VehicleBrowser_Load(object sender, EventArgs e) { if (!this.DesignMode) { this.txtBaseJbrConnAddress.KeyDown -= new KeyEventHandler(FormHelper.EnterToTab); this.txtXuQzcpxh.KeyDown -= new KeyEventHandler(FormHelper.EnterToTab); this.txtTecZkrsh.KeyDown -= new KeyEventHandler(FormHelper.EnterToTab); this.txtXuDescription.KeyDown -= new KeyEventHandler(FormHelper.EnterToTab); this.txtXuPzHm.GotFocus += new EventHandler(txtXuPzHm_GotFocus); SystemConfig config = FT.Commons.Cache.StaticCacheManager.GetConfig<SystemConfig>(); if (config.ReadHgz) { if (!reader.StartWatching()) { MessageBoxHelper.Show("����������ʧ�ܣ�"); } else { reader.RegisterProcesser(ProcessText); } } if (config.UseCardReader) { idReader = new IDCardReaderHelper(new De_ReadICCardComplete(ReadIdCardComplete), config.CardReaderInterval); } CompanyInfo comp = FT.Commons.Cache.StaticCacheManager.GetConfig<CompanyInfo>(); if (this.txtBaseDlrConnAddress.Text.Length==0) this.txtBaseDlrConnAddress.Text = comp.Address; if (this.txtBaseDlrIdCard.Text.Length == 0) this.txtBaseDlrIdCard.Text = comp.BusId; if (this.txtBaseDlrName.Text.Length == 0) this.txtBaseDlrName.Text = comp.Name; if (this.txtBaseDlrPhone.Text.Length == 0) this.txtBaseDlrPhone.Text = comp.Phone; //this.cbXuSellDw.Text = comp.Name; if (this.txtDyDldwConnAddress.Text.Length == 0) this.txtDyDldwConnAddress.Text = comp.Address; if (this.txtDyDldwIdCard.Text.Length == 0) this.txtDyDldwIdCard.Text = comp.BusId; if (this.txtDyDldwName.Text.Length == 0) this.txtDyDldwName.Text = comp.Name; if (this.txtDyDldwPhone.Text.Length == 0) this.txtDyDldwPhone.Text = comp.Phone; if(this.txtBaseSyrIdCard.Text.Length>0) { this.txtBaseSyrRegAddress.Text=FT.Commons.Tools.FormHelper.GetObjectValue(entity, "BaseSyrRegAddress").ToString(); this.txtBaseSyrConnAddress.Text=FT.Commons.Tools.FormHelper.GetObjectValue(entity, "BaseSyrConnAddress").ToString(); } //this.xuhao = this.lbPhotoXh.Text.Trim(); } }
private void button1_Click(object sender, EventArgs e) { reader = new IDCardReaderHelper(new De_ReadICCardComplete(AfterReadIdCard)); }