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. Sending Mail

Sending Mail

Scheduled Pinned Locked Moved ASP.NET
comquestion
3 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.
  • S Offline
    S Offline
    Soumini Ramakrishnan
    wrote on last edited by
    #1

    System.Web.Mail.SmtpMail.Send ("senderID@domainName.com", "receiverID@domainName.com","Subject of the Mail", "Message Body"); I am using SmtpMail in the above manner for sending email. I gave my emailid as receiver address. Eventhough it is showing a success message, when I open my Inbox, it is not there. Why? Thanks in advance.

    P N 2 Replies Last reply
    0
    • S Soumini Ramakrishnan

      System.Web.Mail.SmtpMail.Send ("senderID@domainName.com", "receiverID@domainName.com","Subject of the Mail", "Message Body"); I am using SmtpMail in the above manner for sending email. I gave my emailid as receiver address. Eventhough it is showing a success message, when I open my Inbox, it is not there. Why? Thanks in advance.

      P Offline
      P Offline
      pmarfleet
      wrote on last edited by
      #2

      Unless you are still using .NET 1.1, you should use the System.Net.Mail[^] classes instead. The System.Web.Mail classes are marked as obsolete in Framework v2.0+.

      Paul Marfleet "No, his mind is not for rent To any God or government" Tom Sawyer - Rush

      1 Reply Last reply
      0
      • S Soumini Ramakrishnan

        System.Web.Mail.SmtpMail.Send ("senderID@domainName.com", "receiverID@domainName.com","Subject of the Mail", "Message Body"); I am using SmtpMail in the above manner for sending email. I gave my emailid as receiver address. Eventhough it is showing a success message, when I open my Inbox, it is not there. Why? Thanks in advance.

        N Offline
        N Offline
        N a v a n e e t h
        wrote on last edited by
        #3

        Adding to what Paul said - Your code use local SMTP to send mails. So if it is stopped or not configured correctly, your mails won't get delivered. Look in the PickUp directory or in BadMail directory in MailRoot folder. If mail sending failed, it will be moved to the bad mail directory.

        All C# applications should call Application.Quit(); in the beginning to avoid any .NET problems.- Unclyclopedia How to use google | Ask smart questions

        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