登录 注册
当前位置:主页 > 资源下载 > 10 > GetIP PB is a DLL for acquiring IP addresses.

GetIP PB is a DLL for acquiring IP addresses.

  • 更新:2024-07-23 09:23:20
  • 大小:48KB
  • 推荐:★★★★★
  • 来源:网友上传分享
  • 类别:C++ - 后端
  • 格式:RAR

资源介绍

我试了,支持PB11.5 VC++写的获取本机IP的动态库,并支持多个网卡。 若有多个网卡会用;号分隔开。调用定义 PB调用定义: Function uLong GetHostIpList(ref string hostAddressip) Library "GetIP60.dll" PB11.2调用定义: Function uLong GetHostIpList(ref string hostAddressip) Library "GetIP60.dll" ALIAS FOR "GetHostIpList;ansi" 调用方法 string ls_HostIP = space(128) if GetHostIpList(ls_HostIP) =0 then sle_1.text=trim(ls_HostIP) end if ========================================================== 获取主机名的API PB调用定义: Function uLong Gethost(ref string hostname) Library "GetIP60.dll" PB11.2调用定义: Function uLong Gethost(ref string hostname) Library "GetIP60.dll" ALIAS FOR "Gethost;ansi" 调用方法 string ls_Host = space(256) int result result = Gethost(ls_Host) if result =0 then sle_1.text=trim(ls_Host) end if