public int Reader_CardReset(ref short intReslen, ref string strRes) { byte[] array = new byte[600]; int num = PCSC.PCSC_Connect(PCSC.ReaderN); strRes = ""; int result; if (num != 0) { result = -1; } else { try { num = PCSC.PCSC_CardReset(array, ref intReslen); } catch (Exception var_3_3A) { result = 0; return(result); } if (num != 0) { result = -3; } else { strRes = Encoding.ASCII.GetString(array, 0, (int)(intReslen * 2)); result = 0; } } return(result); }
public int Reader_CardReset(ref short intReslen, ref string strRes) { byte[] TstrRes = new byte[600]; int retval = PCSC.PCSC_Connect(PCSC.ReaderN); strRes = ""; int result; if (retval != 0) { result = -1; } else { try { retval = PCSC.PCSC_CardReset(TstrRes, ref intReslen); } catch (Exception e_3A) { result = 0; return(result); } if (retval != 0) { result = -3; } else { strRes = Encoding.ASCII.GetString(TstrRes, 0, (int)(intReslen * 2)); result = 0; } } return(result); }