Example #1
0
        //读取身份证信息
        public static int ReadCard()
        {
            //用于读卡器与身份证建立连接
            int authen = CVRSDK.CVR_Authenticate();

            if (authen != 1)
            {
                return(-1);            //卡片放置位置不正确
            }
            else
            {
                int readContent = CVRSDK.CVR_Read_Content(4);
                if (readContent == 2)
                {
                    return(1);//"读卡操作成功!";
                }
                else
                {
                    return(0); //"读卡操作失败!";
                }
            }
        }