请问vb->delphi中的字符串用pchar还是string,为什么我下面的vb转换delphi代码不行?
Declare Function write_card Lib "STICCW32.DLL" (ByVal hiCC%, ByVal zone%, ByVal addr%, ByVal data_len%, ByVal dat$) As Integer
Private Sub Command8_Click()
Dim sTmp As String
sTmp = Trim(Text7.Text)
nstatus% = write_card(nhiCC, 0, 32, 10, sTmp)
If nstatus = 0 Then
MsgBox "OK!"
Else
MsgBox "error!"
End If
end sub
出错的原因在于不知sTmp变量为什么类型?以及dll文件函数中的dat为何类型?