⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 form1.frm

📁 VB编写刷流量工具
💻 FRM
字号:
VERSION 5.00
Object = "{F9043C88-F6F2-101A-A3C9-08002B2F49FB}#1.2#0"; "COMDLG32.OCX"
Object = "{48E59290-9880-11CF-9754-00AA00C00908}#1.0#0"; "MSINET.OCX"
Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0"; "MSCOMCTL.OCX"
Begin VB.Form Form1 
   BorderStyle     =   1  'Fixed Single
   Caption         =   "刷流量暴强工具  --By  无敌小龙  QQ:5450913"
   ClientHeight    =   4905
   ClientLeft      =   4905
   ClientTop       =   2880
   ClientWidth     =   11415
   LinkTopic       =   "Form1"
   MaxButton       =   0   'False
   ScaleHeight     =   4905
   ScaleWidth      =   11415
   Begin InetCtlsObjects.Inet Inet1 
      Index           =   0
      Left            =   4800
      Top             =   4200
      _ExtentX        =   1005
      _ExtentY        =   1005
      _Version        =   393216
      AccessType      =   2
   End
   Begin VB.Frame Frame2 
      Caption         =   "程序进度:"
      Height          =   3975
      Left            =   5640
      TabIndex        =   5
      Top             =   120
      Width           =   5295
      Begin VB.ListBox List2 
         Height          =   3120
         Left            =   240
         TabIndex        =   7
         Top             =   240
         Width           =   4935
      End
      Begin MSComctlLib.ProgressBar ProgressBar1 
         Height          =   255
         Left            =   240
         TabIndex        =   6
         Top             =   3600
         Width           =   4935
         _ExtentX        =   8705
         _ExtentY        =   450
         _Version        =   393216
         Appearance      =   1
      End
   End
   Begin VB.Frame Frame1 
      Caption         =   "操作区:"
      Height          =   3975
      Left            =   120
      TabIndex        =   0
      Top             =   120
      Width           =   5295
      Begin VB.ListBox List1 
         Height          =   2940
         Left            =   240
         TabIndex        =   4
         Top             =   840
         Width           =   3375
      End
      Begin VB.TextBox Text1 
         Height          =   375
         Left            =   240
         TabIndex        =   3
         Text            =   "http://pespin.ys168.com"
         Top             =   360
         Width           =   3375
      End
      Begin VB.CommandButton Command2 
         Caption         =   "测试"
         Height          =   375
         Left            =   3840
         TabIndex        =   2
         Top             =   360
         Width           =   1215
      End
      Begin VB.CommandButton Command1 
         Caption         =   "载入列表"
         Height          =   375
         Left            =   3840
         TabIndex        =   1
         Top             =   3360
         Width           =   1215
      End
   End
   Begin MSComDlg.CommonDialog CommonDialog1 
      Left            =   4080
      Top             =   4200
      _ExtentX        =   847
      _ExtentY        =   847
      _Version        =   393216
   End
   Begin VB.Label Label1 
      Caption         =   "无敌小龙'Blog:vhttp://hi.baidu.com/pespin"
      Height          =   255
      Left            =   7080
      TabIndex        =   8
      Top             =   4440
      Width           =   3855
   End
End
Attribute VB_Name = "Form1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command1_Click()
CommonDialog1.ShowOpen '打开对话框
If CommonDialog1.FileName <> "" Then '如果对话框的文件名不为空,就执行下面的代码
   List1.Clear
   Open CommonDialog1.FileName For Input As #1
      Do Until EOF(1) = True '循环载入IP地址列表
         Line Input #1, a
         List1.AddItem a
      Loop
   Close
Else
End If
ProgressBar1.Min = 0 '初始化滚动条的最大和最小属性
ProgressBar1.Max = List1.ListCount - 1
End Sub

Private Sub Command2_Click()
On Error Resume Next
If List1.ListCount = 0 Then Exit Sub '如果没有载入代理IP地址就不扫描
If Text1.Text = "" Then Exit Sub '如果目标网站为空就退出程序运行

For i = 0 To List1.ListCount - 1 '遍历列表框一中的所有IP地址
   Load Inet1(i) '载入一个新的inet
   Inet1(i).Cancel '断开连接
   Inet1(i).Proxy = List1.List(i) '设置代理
   Inet1(i).Execute Text1.Text, "get" '发送get请求
   ProgressBar1.Value = i '设置进度条的进度
Next
End Sub

Private Sub Inet1_StateChanged(Index As Integer, ByVal State As Integer)
On Error Resume Next
If State = 11 Then '11就是连接错误
   a = Inet1(Index).GetHeader
   a = Mid(a, 1, InStr(1, a, vbCrLf)) '分解出消息头
   List2.AddItem List1.List(Index) & "  连接错误  " & a
   
   Inet1(Index).Cancel '关闭inet
   Unload Inet1(Index) '卸载inet
   ProgressBar1.Value = ProgressBar1.Value - 1 '进度条减少一个单位进度
ElseIf State = 12 Then '12就是连接成功
   a = Inet1(Index).GetHeader
   a = Mid(a, 1, InStr(1, a, vbCrLf)) '分解出消息头
   List2.AddItem List1.List(Index) & "  连接成功  " & a
   
   Inet1(Index).Cancel
   Unload Inet1(Index)
   ProgressBar1.Value = ProgressBar1.Value - 1
End If
End Sub

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -