////// 方法委托 /// /// /// /// public delegate void GetFingerInfor_Delegate(string dwEnrollNum, string enrolldata, int dwMachineID); ////// 为控件赋值 /// /// /// /// public void GetFingerInfor(string dwEnrollNum, string enrolldata, int dwMachineID) { try { Btn_Read.Text = "读取指纹"; txt_id.Text = dwEnrollNum; txt_fingerprint.Text = enrolldata; //关闭监听 bool b_end = Fingerprint.EndListen(axSB100PC1, dwMachineID); } catch (Exception ex) { string str_ex = ex.ToString(); } }
//调用方法 GetFingerInfor_Delegate fingerInfor = new GetFingerInfor_Delegate(GetFingerInfor); this.BeginInvoke(fingerInfor, new object[] { dwEnrollNum.ToString(), enrolldata, dwMachineID });