send multiple emails

Posted on 2011-10-28
Last Modified: 2012-05-12
   inside txtemail.Text I want to add more than 1 email     ie.;

Right now it only let me send 1 email.   How can I accomplish this?

__________code below_______________

  emailRecipients = txtemail.Text

 Dim objEmail As MailMessage = New MailMessage()
        Dim subjToUse As String = "Approved Application (For internal use only)"

        objEmail.To.Add(New MailAddress(emailRecipients))
        objEmail.CC.Add(New MailAddress(""))
        objEmail.From = New MailAddress("")
        objEmail.Subject = subjToUse
        objEmail.Body = smsg
        objEmail.IsBodyHtml = True
        Dim client As SmtpClient = New SmtpClient("")
Question by:Wigging
    1 Comment
    LVL 69

    Accepted Solution

    as you can see in

        'able to handle more then a single recipient
        strAddresses = txtTo.Text.Replace(",", ";")
        For Each strX As String In strAddresses.Split(";"c)
            If strX.Trim.Length > 0 Then
                .To.Add(New MailAddress(strX))
            End If

    Featured Post

    Looking for New Ways to Advertise?

    Engage with tech pros in our community with native advertising, as a Vendor Expert, and more.

    Join & Write a Comment

    In my previous two articles we discussed Binary Serialization ( and XML Serialization ( In this article we will try to know more about SOAP (Simple Object Acces…
    Today I had a very interesting conundrum that had to get solved quickly. Needless to say, it wasn't resolved quickly because when we needed it we were very rushed, but as soon as the conference call was over and I took a step back I saw the correct …
    how to add IIS SMTP to handle application/Scanner relays into office 365.
    This video is in connection to the article "The case of a missing mobile phone (". It will help one to understand clearly the steps to track a lost android phone.

    745 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    16 Experts available now in Live!

    Get 1:1 Help Now