求助:调用类dll问题
[DllImport("MF_DLL.DLL")]public static extern int mf_Connect();连接读卡器
[DllImport("MF_DLL.DLL")]
public static extern bool mf_Disconnect();断开
[DllImport("MF_DLL.DLL")]
public static extern int mf_ReadRfid(StringBuilder id, StringBuilder type);读卡
private void button8_Click(object sender, EventArgs e)
{
textBox5.Text = "";
mf_Connect();
StringBuilder id1 = new StringBuilder();
StringBuilder type1 = new StringBuilder();
mf_ReadRfid(id1, type1);
this.textBox5.Text =type1 . ToString ();
this.textBox5.Text =id1 . ToString ();
mf_Disconnect();
}
这是调用的一个开发包!现在怎么type1是乱码
id1是空的呀
int mf_ReadRfid(unsigned char *id, unsigned char *type);
// 读ID卡卡号
// id=卡号4字节数据,高字节在前
// type=厂商代码
这是说明
麻烦各位给指点一下