Register

If this is your first visit, please click the Sign Up now button to begin the process of creating your account so you can begin posting on our forums! The Sign Up process will only take up about a minute of two of your time.

Results 1 to 7 of 7

Thread: Sending mail

  1. #1
    Senior Member echoSwe's Avatar
    Join Date
    May 2004
    Posts
    332
    Member #
    5926
    Hi all...

    A simple question about IIS 5 - IIS 6. How do you make the e-mail client:
    MailMessage mail = new MailMessage();
    using System.Web.Mail

    use special characters in the mails? I'm from Sweden and we send emails using the characters and . Post these and they simply don't show up. HELP! Quickly!

  2.  

  3. #2
    Senior Member echoSwe's Avatar
    Join Date
    May 2004
    Posts
    332
    Member #
    5926
    Yet again I got the answer in another forum. Hmm. It seems like there is a lack of knowledge here...
    PM me for the solution.

  4. #3
    Senior Member echoSwe's Avatar
    Join Date
    May 2004
    Posts
    332
    Member #
    5926
    One last thingy:
    Since everyone seems so eager to know how to send mail via ASP .Net (according to the views statistics) I recommend this link:
    http://www.systemwebmail.com/faq/2.aspx
    //Henke

  5. #4
    Senior Member rosland's Avatar
    Join Date
    Jul 2003
    Location
    Norway
    Posts
    1,944
    Member #
    2096
    Quote Originally Posted by echoSwe
    Yet again I got the answer in another forum. Hmm. It seems like there is a lack of knowledge here...
    With regard to ASP you're halfway right. There are a few highly skilled ASP members here, but they're a small minority (unfortunately, as we would like to have a member base as broad as possible in the coding community.)


    Quote Originally Posted by echoSwe
    PM me for the solution.
    Beeing one of the few ASP/ASP.NET addicted users, we would very much appreciate if you laid out your solutions in the forums for all to see, instead of cloaking them through PM's.
    S. Rosland

  6. #5
    ACW
    ACW is offline
    Member
    Join Date
    Jul 2004
    Posts
    82
    Member #
    6554
    Here is one way to use it with authentication.

    Code:
    Dim mailMessage As System.Web.Mail.MailMessage
    
    mailMessage.To = ""
    mailMessage.From = ""
    mailMessage.Subject = ""
    mailMessage.BodyFormat = System.Web.Mail.MailFormat.Text
    mailMessage.Body = ""
    
    mailMessage.Fields.Add("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate", "1") 'basic authentication
    mailMessage.Fields.Add("http://schemas.microsoft.com/cdo/configuration/sendusername", "username") 'set your username here
    mailMessage.Fields.Add("http://schemas.microsoft.com/cdo/configuration/sendpassword", "password") 'set your password here
    
    System.Web.Mail.SmtpMail.SmtpServer = "" 'URL to mail server
    
    System.Web.Mail.SmtpMail.Send(mailMessage)
    
    mailMessage = Nothing
    Affordable Business Web Site Hosting by Geo Redundant Hosting

  7. #6
    Senior Member echoSwe's Avatar
    Join Date
    May 2004
    Posts
    332
    Member #
    5926
    Alright thanks. Rosland:
    I did provide an address for them to read about system.web.mail... so... I've searched a lot afer this so I don't think there is any other topics about this problem - doesn't seem like many people have it. Also noone has PM:ed me, and if they wanted a solution they could just say so in this thread - right?

    ACW: How does the authentication work? Is it through SSL? Why do you use MS addresses?

  8. #7
    ACW
    ACW is offline
    Member
    Join Date
    Jul 2004
    Posts
    82
    Member #
    6554
    Many mail servers require the sender to authenticate with a valid user name and password before sending emails. This prevents the server from being used for spam. So all it does is make sure that you have a valid account on the server - no SSL or encryption is involved.

    As far a the "MS addresses" - that is the way you tell it that you want to use authentication and allows you to set the user name and password. I've yet to find any other way to set that information. I think I read somewhere that authentication was kind of an afterthought - after many complaints, I'm sure. That would explain the awkward way to set it.
    Affordable Business Web Site Hosting by Geo Redundant Hosting


Remove Ads

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT -6. The time now is 07:07 PM.
Powered by vBulletin® Version 4.2.3
Copyright © 2021 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: PurevB.com