locked
How to extract all emails in the website from all its links just by typing its address in textbox1? RRS feed

  • Question

  • hi all experts

    Iam still beginner

    and I have used the following code to get all email addresses in web site

    Imports System.Text.RegularExpressions
    Public Class Form1

        Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
            Dim myRequest As Net.WebRequest = Net.WebRequest.Create(Me.TextBox1.Text)
            Dim myResponse As Net.WebResponse = myRequest.GetResponse()
            Dim sreader As IO.StreamReader = New IO.StreamReader(myRequest.GetResponse().GetResponseStream())
            Dim webString As String = sreader.ReadToEnd()

            Dim adrRx As Regex = New Regex("\b[a-z0-9._%+-]+@[a-z0-9.-]+\.[a-z]{2,4}\b")
            Dim emails As New List(Of String)
            For Each item As Match In adrRx.Matches(webString.ToLower)
                If Not emails.Contains(item.Value) Then emails.Add(item.Value)
            Next
            Dim emailsString As String = Join(emails.ToArray, "; ")
            Me.TextBox2.Text = emailsString

        End Sub

    but now  I wanna to extract all emails in the website from all its links just by typing its address in textbox1


    Thursday, July 7, 2011 6:35 AM

Answers

  • Hi Oman,

    It is possible but i am not going to share it. As there is no need of such application.

     

    Try to use your brain in a solid progressive way.

    Thanks.


    If my post answers your question then mark as answer.
    • Proposed as answer by Heslacher Friday, July 8, 2011 6:18 AM
    • Marked as answer by config2002 Friday, July 8, 2011 6:55 AM
    Friday, July 8, 2011 5:58 AM

All replies

  • Hi Oman,

    You want to go to jail? 

    In many countries the penalty for what you currently try to do is very high.

     

     


    Success
    Cor
    • Proposed as answer by Heslacher Friday, July 8, 2011 6:18 AM
    Thursday, July 7, 2011 6:59 AM
  • hi

    Iam still beginner and am using vb2005

    with this code I can   extract all emails in the website by typing its address in textbox1

    Imports System.Text.RegularExpressions
    Public Class Form1

        Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
            Dim myRequest As Net.WebRequest = Net.WebRequest.Create(Me.TextBox1.Text)
            Dim myResponse As Net.WebResponse = myRequest.GetResponse()
            Dim sreader As IO.StreamReader = New IO.StreamReader(myRequest.GetResponse().GetResponseStream())
            Dim webString As String = sreader.ReadToEnd()

            Dim adrRx As Regex = New Regex("\b[a-z0-9._%+-]+@[a-z0-9.-]+\.[a-z]{2,4}\b")
            Dim emails As New List(Of String)
            For Each item As Match In adrRx.Matches(webString.ToLower)
                If Not emails.Contains(item.Value) Then emails.Add(item.Value)
            Next
            Dim emailsString As String = Join(emails.ToArray, "; ")
            Me.TextBox2.Text = emailsString

     

    End Sub

    but I want to know how  to extract all emails in the website from all its links just by typing its address in textbox1?


    • Merged by Kee Poppy Tuesday, July 12, 2011 7:23 AM duplicate thread
    Thursday, July 7, 2011 7:27 AM
  • Thursday, July 7, 2011 8:10 AM
  • Hi Oman,

    You want to go to jail? 

    In many countries the penalty for what you currently try to do is very high.

     

     


    Success
    Cor


    its not like that man

    am not ganna use it in wrong way

    Thursday, July 7, 2011 8:25 PM
  • Hi Oman,

    It is possible but i am not going to share it. As there is no need of such application.

     

    Try to use your brain in a solid progressive way.

    Thanks.


    If my post answers your question then mark as answer.
    • Proposed as answer by Heslacher Friday, July 8, 2011 6:18 AM
    • Marked as answer by config2002 Friday, July 8, 2011 6:55 AM
    Friday, July 8, 2011 5:58 AM
  • Hi Oman,

    It is possible but i am not going to share it. As there is no need of such application.

     

    Try to use your brain in a solid progressive way.

    Thanks.


    If my post answers your question then mark as answer.


    Dear brother dont understand me wrong

    I dont mean that I want to make malware app or some thing like that

    I need this code just to extract all emails in available pages in the website from all its available  links just by typing its address in textbox1 instead of type all its pages one by one

    but not meaning private pages that I have no permission to access them

    Saturday, July 9, 2011 3:07 PM