读书人

API函数

发布时间: 2012-02-05 12:07:15 作者: rapoo

求助API函数
在全局扩展函数里写了
function boolean GetComputerNameA(ref string cn name,ref long nbuf)Library "kemel32.dll"
button的clicked事件写
string ls_computer
long ll_buf
ll_buf = 25
ls_computer = space(ll_buf)
getcomputernamea(ls_computer,ll_buf)
SetProfileString("send.log","computername","computername",ls_computer)
为什么这个函数没有获取到?

[解决办法]
pb版本10以上用这个
Function ulong GetComputerName(ref string lpBuffer,ref ulong nSize)
LIBRARY "kernel32.dll" ALIAS FOR "GetComputerNameA;ansi"
[解决办法]

探讨

好像是电脑中没有相应的DLL文件 API函数都用到哪些DLL文件 谁能给我传一份
myemail_bake@163.com

读书人网 >PB

热点推荐