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
  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 glyakk's Avatar
    Join Date
    Nov 2003
    Location
    USA
    Posts
    1,263
    Member #
    3828
    Liked
    6 times
    Have you tried to use these 'character codes'? å ã õ

    I am guessing you would need a script that could parse your documents, replacing the orgional character with the equivilent 'character code'.


  4. #3
    Senior Member echoSwe's Avatar
    Join Date
    May 2004
    Posts
    332
    Member #
    5926
    Quote Originally Posted by glyakk
    Have you tried to use these 'character codes'? å ã õ

    I am guessing you would need a script that could parse your documents, replacing the orgional character with the equivilent 'character code'.
    Yeah, that would do the trick! Something like:

    string body = Request.Form["body"];
    for (int i = 0; i < body.length(); i++) {
    switch (body.at[i])
    {
    case "":
    body.at[i] = "&auml;";
    case :
    ...
    Default:
    ...
    }
    }

    I'm an old C++ programmer so I know the syntax is partly wrong - could anyone please help me with this? And doesn't the ; in the &auml; break the row in the code?
    I need to refer to the sign... Is this how I do it?

    //Henke

  5. #4
    Senior Member rosland's Avatar
    Join Date
    Jul 2003
    Location
    Norway
    Posts
    1,944
    Member #
    2096
    I'm not familiar with ASP, but it's quite easy to do in PHP.

    I guess VB has some built in support for regular expresisons (at least rudimentary?)
    If so, it's just to run the VB equivalent of 'str_replace' / 'ereg_replace' / 'preg_replace' or whatever have you.

    The code won't be broken by the semicolons as long as they are defined as string values inside quotes (at least not in PHP). If they do, you could try to escape them (\; ).
    S. Rosland

  6. #5
    Senior Member echoSwe's Avatar
    Join Date
    May 2004
    Posts
    332
    Member #
    5926
    Quote Originally Posted by rosland
    I'm not familiar with ASP, but it's quite easy to do in PHP.

    I guess VB has some built in support for regular expresisons (at least rudimentary?)
    If so, it's just to run the VB equivalent of 'str_replace' / 'ereg_replace' / 'preg_replace' or whatever have you.

    The code won't be broken by the semicolons as long as they are defined as string values inside quotes (at least not in PHP). If they do, you could try to escape them (\; ).
    Yeah... Quite easy in C++ too... Just gotta know how to handle the strings. Gonna google some.

  7. #6
    Senior Member echoSwe's Avatar
    Join Date
    May 2004
    Posts
    332
    Member #
    5926
    Wait... Or u can do something with the mail.bodyEncode ??

  8. #7
    Senior Member echoSwe's Avatar
    Join Date
    May 2004
    Posts
    332
    Member #
    5926
    Fixed it.


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 06:54 PM.
Powered by vBulletin® Version 4.2.3
Copyright © 2021 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: PurevB.com