Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. Email in Asp.Net 2.0

Email in Asp.Net 2.0

Scheduled Pinned Locked Moved ASP.NET
questioncsharpasp-netcomsysadmin
7 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • F Offline
    F Offline
    freshonlineMax
    wrote on last edited by
    #1

    Hello I can't send email. What is smtp server? What is host name? I know my mail server ip, my email's user and pass. Now how can i send mail to users and get their feedback. I test many states but i failed... Example:: My Email : info@mysite.com Target User : user@yahoo.com My Server : www.mellihost.com Server Ip : 70.84.176.94 Now please help me. Regards

    M V 2 Replies Last reply
    0
    • F freshonlineMax

      Hello I can't send email. What is smtp server? What is host name? I know my mail server ip, my email's user and pass. Now how can i send mail to users and get their feedback. I test many states but i failed... Example:: My Email : info@mysite.com Target User : user@yahoo.com My Server : www.mellihost.com Server Ip : 70.84.176.94 Now please help me. Regards

      M Offline
      M Offline
      Michael Sync
      wrote on last edited by
      #2

      You can ask your hosting company about the address of smtp srv.. normally, it works with localhost..

      Thanks and Regards, Michael Sync ( Blog: http://michaelsync.net)

      F 1 Reply Last reply
      0
      • F freshonlineMax

        Hello I can't send email. What is smtp server? What is host name? I know my mail server ip, my email's user and pass. Now how can i send mail to users and get their feedback. I test many states but i failed... Example:: My Email : info@mysite.com Target User : user@yahoo.com My Server : www.mellihost.com Server Ip : 70.84.176.94 Now please help me. Regards

        V Offline
        V Offline
        Vasudevan Deepak Kumar
        wrote on last edited by
        #3

        freshonlineMax wrote:

        What is smtp server? What is host name?

        Your web host is the best contact to give you the optimal values for these queries for your domain.

        Vasudevan Deepak Kumar Personal Homepage Tech Gossips
        Yesterday is a canceled check. Tomorrow is a promissory note. Today is the ready cash. USE IT.

        1 Reply Last reply
        0
        • M Michael Sync

          You can ask your hosting company about the address of smtp srv.. normally, it works with localhost..

          Thanks and Regards, Michael Sync ( Blog: http://michaelsync.net)

          F Offline
          F Offline
          freshonlineMax
          wrote on last edited by
          #4

          Ok, But my host couldn't help me well. Can you send some code using my sample options to help me? Tanks

          M 1 Reply Last reply
          0
          • F freshonlineMax

            Ok, But my host couldn't help me well. Can you send some code using my sample options to help me? Tanks

            M Offline
            M Offline
            Michael Sync
            wrote on last edited by
            #5

            http://www.google.com/search?q=asp.net+send+mail&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:en-US:official&client=firefox-a[^] Dim MailObj As New System.Net.Mail.SmtpClient MailObj.Host = "localhost" MailObj.Send(EmFrom.Text, EmTo.Text, EmSubj.Text, EmMsg.Text)

            Thanks and Regards, Michael Sync ( Blog: http://michaelsync.net)

            F 1 Reply Last reply
            0
            • M Michael Sync

              http://www.google.com/search?q=asp.net+send+mail&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:en-US:official&client=firefox-a[^] Dim MailObj As New System.Net.Mail.SmtpClient MailObj.Host = "localhost" MailObj.Send(EmFrom.Text, EmTo.Text, EmSubj.Text, EmMsg.Text)

              Thanks and Regards, Michael Sync ( Blog: http://michaelsync.net)

              F Offline
              F Offline
              freshonlineMax
              wrote on last edited by
              #6

              Hello Dear Michael I'm a professional desktop developer (C# base), but in sending mail, i really confused. I developed a website for somebody and i'm in final step. As you said and in this way anybody can send email from anybody to anybody..! I want to say that: Do i need username, password and real host name or not? I tested this code and i saw no mail in my inbox. Please notice that i made no change on your code. So please help me again if you have time. Tanx

              M 1 Reply Last reply
              0
              • F freshonlineMax

                Hello Dear Michael I'm a professional desktop developer (C# base), but in sending mail, i really confused. I developed a website for somebody and i'm in final step. As you said and in this way anybody can send email from anybody to anybody..! I want to say that: Do i need username, password and real host name or not? I tested this code and i saw no mail in my inbox. Please notice that i made no change on your code. So please help me again if you have time. Tanx

                M Offline
                M Offline
                Michael Sync
                wrote on last edited by
                #7

                Hi,

                freshonlineMax wrote:

                Do i need username, password and real host name or not?

                You need to define the host name, the SMTP server.... In ASP.NET, you can use either System.Web.Mail or System.Net.Mail for sending emails.. but defining the SMTP server is a must in ASP.NET... The name of SmtpServer are vary from one host to another.. When I was hosting my site in DisccountASP.NET, I can use "localhost" as the SmtpServer... here is the article from DiscountASP.NET Knowledge Base.

                Thanks and Regards, Michael Sync ( Blog: http://michaelsync.net)

                1 Reply Last reply
                0
                Reply
                • Reply as topic
                Log in to reply
                • Oldest to Newest
                • Newest to Oldest
                • Most Votes


                • Login

                • Don't have an account? Register

                • Login or register to search.
                • First post
                  Last post
                0
                • Categories
                • Recent
                • Tags
                • Popular
                • World
                • Users
                • Groups