Imports System.Net, Microsoft.Win32 Imports System.Management Imports System.IO Imports System.Security.Cryptography Imports System.Text Imports System.Threading Public Class Login Dim Username As String Dim All As String Dim Logins As String = 0 Private Sub LoginButton_Click(sender As Object, e As EventArgs) Handles LoginButton.Click Logins = Logins + 1 If logins = 4 Then MsgBox("You have tried to log in to many times. The application will now close.") Application.Exit() Exit Sub End If Dim Web As New WebClient() Dim I As String = TextBox1.Text & ":" & TextBox2.Text Dim response As String = Web.DownloadString("https://dl.dropbox.com/s/12ny0uh83qpa2cb/Account.txt?dl=0") If response.Contains(I) Then Else : MsgBox("Invalid Login.", MsgBoxStyle.Information) Exit Sub End If If TextBox1.Text = "" Or TextBox2.Text = "" Then MsgBox("Please enter a valid Username and Password.") Else MsgBox("Welcome " + TextBox1.Text) Home.Show() Me.Close() End If End Sub Private Sub Login_Load(sender As Object, e As EventArgs) Handles MyBase.Load Textbox3.Text = Dns.GetHostEntry(Dns.GetHostName).AddressList(0).ToString() End Sub End Class