当前位置: 代码迷 >> PB >> 如何取得计算机名
  详细解决方案

如何取得计算机名

热度:98   发布时间:2016-04-29 09:27:35.0
怎么取得计算机名 ?
不知道该怎么调用,特来请教,望能给个完整的代码,谢谢

------解决方案--------------------
API
FUNCTION ulong GetComputerName(ref string lpBuffer,ref ulong nSize) 
LIBRARY "kernel32.dll" ALIAS FOR "GetComputerNameA"



string s
ulong l
l = 100
GetComputerName(s,l)
messagebox('a',s)
  相关解决方案