关注分享主机优惠活动
国内外VPS云服务器

IFIX主机计算机网络测试屏幕

IFIX主机增加IP测试

影响

实现图

实现脚本

Option显式私有声明函数GetExitCodeProcess Lib " kernel 32 "(_ ByVal hProcess As Long,_ lpExitCode As Long)私有声明函数close handle Lib " kernel 32 "(_ ByVal hObject As Long)私有声明函数open process Lib " kernel 32 "(_ ByVal dwDesiredAccess As Long,_ ByVal bInheritHandle As Long, _ ByVal dwProcessId As Long)As Long Const PROCESS _ QUERY _ INFORMATION = & h 400 Const STILL _ ALIVE = & h103 private Sub text 2 _ Click()Dim PID As Long PID = Shell(" cmd . exe/C Ping " & " 192 . 168 . 0 . 135 " & " > C:/ipaac . txt ",vbHide)Dim hProc As Long hProc = open PROCESS(PROCESS _ QUERY _ INFORMATION,0,PID)Dim exit code As Long Do Call getexitcode PROCESS(hProc caption = " " Open " c:/ipaac . txt " For Input As # 1 Dim strLine As String Do Until EOF(1)Line Input # 1,strLine Text3。标题=文本3。Caption & strLine & vbNewLine出现错误时循环关闭#1,出现错误时恢复下一个Kill " c:/ipaac . txt " GoTo 0 end Sub

未经允许不得转载:主机频道 » IFIX主机计算机网络测试屏幕

相关推荐

评论 抢沙发

评论前必须登录!