Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- 'module Mod1
- Imports System.Net
- Imports System.IO
- Module Mod1
- Public Function fileDialogg(ByRef a As Windows.Forms.FileDialog, ByRef b As String) As Boolean
- Try
- a.InitialDirectory = "C:\Users\%current user%\Desktop\"
- a.Filter = "Text Files|*.txt"
- a.ShowDialog()
- b = a.FileName.ToString()
- Return True
- Catch ex As Exception
- MsgBox("fd fail")
- Return False
- End Try
- End Function
- Public Function read1(ByVal location1 As String, ByRef output As ArrayList) As Boolean
- Try
- Dim lines() As String = IO.File.ReadAllLines(location1)
- Dim lineArray As New ArrayList()
- For x As Integer = 0 To lines.GetUpperBound(0)
- lineArray.Add(lines(x))
- Next
- output = lineArray
- Return True
- Catch ex As Exception
- MsgBox("reading failure")
- Return False
- End Try
- End Function
- Public Function reqprxyCHECK(ByVal prox As String) As String
- Try
- Dim pppp As String() = prox.Split(New String() {":"}, StringSplitOptions.None)
- Dim getR As HttpWebRequest = DirectCast(WebRequest.Create("http://www.shroomery.org/ythan/proxycheck.php?ip=" & pppp(0)), HttpWebRequest)
- getR.Method = "GET"
- getR.Proxy = New WebProxy(prox)
- getR.Timeout = 10000
- getR.Referer = "https://www.google.com/"
- getR.UserAgent = "Mozilla/5.0 (Windows NT 6.1; rv:26.0) Gecko/20100101 Firefox/26.0"
- Dim getResponse As HttpWebResponse
- getResponse = DirectCast(getR.GetResponse(), HttpWebResponse)
- Dim getRReader As New StreamReader(getResponse.GetResponseStream())
- Dim thepage As String = getRReader.ReadToEnd
- Return thepage
- Catch ex As Exception
- Return "F"
- End Try
- End Function
- Public Function prxyCHECK(ByVal page As String) As Boolean
- Try
- If page.Contains("N") Then
- Return True
- Else
- Return False
- End If
- Catch ex As Exception
- Return False
- End Try
- End Function
- End Module
- 'form1
- Public Class Form1
- Public unchecked As New ArrayList
- Public spn As Integer
- Public checked As String
- Public Sub chk()
- Me.BackColor = Color.Coral
- For i = 0 To unchecked.Count - 1
- If prxyCHECK(reqprxyCHECK(unchecked(i))) = True Then
- checked = checked & unchecked(i) & Environment.NewLine
- End If
- Next
- Me.BackColor = Color.AliceBlue
- End Sub
- Public Sub chkMT()
- line1: If spn <= unchecked.Count - 1 Then
- Dim a As String = unchecked(spn)
- spn += 1
- If prxyCHECK(reqprxyCHECK(a)) = True Then
- checked = checked & a & Environment.NewLine
- Label5.Text = (Val(Label5.Text) + 1).ToString
- End If
- Label3.Text = (Val(Label3.Text) + 1).ToString
- GoTo line1
- Else
- Exit Sub
- End If
- End Sub
- #region "designs"
- Dim drag As Boolean
- Dim mousex As Integer
- Dim mousey As Integer
- Private Sub button3_MouseDown(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles Button3.MouseDown
- drag = True
- mousex = Windows.Forms.Cursor.Position.X - Me.Left
- mousey = Windows.Forms.Cursor.Position.Y - Me.Top
- End Sub
- Private Sub button3_MouseMove(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles Button3.MouseMove
- If drag = True Then
- Me.Top = Windows.Forms.Cursor.Position.Y - mousey
- Me.Left = Windows.Forms.Cursor.Position.X - mousex
- End If
- End Sub
- Private Sub button3_MouseUp(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles Button3.MouseUp
- drag = False
- End Sub
- Private Sub Button3_MouseWheel(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.MouseWheel
- Me.WindowState = FormWindowState.Minimized
- End Sub
- Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click
- Me.Close()
- End Sub
- Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
- Me.ActiveControl = Button3
- System.Windows.Forms.Control.CheckForIllegalCrossThreadCalls = False
- End Sub
- #end region
- Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
- fileDialogg(OpenFD1, TextBox1.Text)
- read1(TextBox1.Text, unchecked)
- End Sub
- Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
- SaveFD1.Filter = "TXT Files (*.txt*)|*.txt"
- If SaveFD1.ShowDialog = Windows.Forms.DialogResult.OK Then
- My.Computer.FileSystem.WriteAllText(SaveFD1.FileName, checked, True)
- End If
- End Sub
- Private Sub Button5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button5.Click
- Label2.Text = unchecked.Count.ToString
- For i = 0 To 49
- Dim th As System.Threading.Thread
- th = New System.Threading.Thread(AddressOf chkMT)
- th.IsBackground = True
- th.Start()
- Label7.Text = (Val(Label7.Text) + 1).ToString
- Next
- End Sub
- End Class
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement