European accent

Hi all,
when I try to send a mail with an accented letter in subject (or in body) outlook does not display it properly
I've tried to encode subject with MimeUtility but the only
way I found is to encode it in UTF-8 (I want iso-8859-1 !!!) so outlook users have to configure it to see all right.
Someone can post a snippet of code with some solution?
Leonardo

Try this sample code
   public void sendMail(
            String sTo,
            String sCarbonCopy,
            String sBlindCarbonCopy,
            String sReplyTo,
            String sFrom,                 
            String sAsunto,  //subject
            String sTextoMensaje, //body
            DataSource dsAttachment) //attach. it must be null if there is no attachment.
            throws AddressException, MessagingException, java.io.IOException{
            Properties props = System.getProperties();
            props.put("mail.smtp.host", "your_mail_server");
            // Create a session
            Session session = Session.getDefaultInstance(props, null);
            session.setDebug(true);
            // construct the message
            Message msg = new MimeMessage(session);
            msg.setFrom(new InternetAddress(sFrom));
            msg.setRecipients(Message.RecipientType.TO,
            InternetAddress.parse(sTo, false));    
            if (sCarbonCopy != null) {
                msg.setRecipients(
                 Message.RecipientType.CC,
                InternetAddress.parse(sCarbonCopy,
                false));       
            if (sBlindCarbonCopy != null) {
                msg.setRecipients(
                Message.RecipientType.BCC,
                InternetAddress.parse(sBlindCarbonCopy, false));           
            if (sReplyTo != null) {
             msg.setReplyTo(InternetAddress.parse(sReplyTo,false));
            msg.setSubject(sAsunto);
            MimeBodyPart mbp1 = new MimeBodyPart();
            mbp1.setContent(sTextoMensaje,"text/plain");
            Multipart mp = new MimeMultipart();
            mp.addBodyPart(mbp1);
            if (dsAttachment!=null) {
             // create the second message part i.e. attachment
     MimeBodyPart mbp2 = new MimeBodyPart();
     // attach the file to the message          
     mbp2.setDataHandler(new DataHandler(dsAttachment));
     mbp2.setFileName(dsAttachment.getName());
     // add the attach
     mp.addBodyPart(mbp2);       
            // add the Multipart to the message
            msg.setContent(mp);
            setMessage(msg);
            Transport.send(msg);
    }It worked for me :)

Similar Messages

  • CF Builder and various european accents

    I am unable to edit properly French accents (in templates coming from Dreamweaver) with CF Builder. I cant write HTML entities, but may be somebody has a better solution ?

    Hi! Today is my first day using this tool and came across the same problem. Follow the path: WINDOW>PREFERENCES>GENERAL>WORKSPACE. Change the radio button "text file encoding = default: UTF-8" to "other:ISO-8859-1".

  • "*" symbol at the beginning of TAB

    Hello,
    My problem is that I just installed new font called "Palemonas" and there is weird bug with Pages. Each time I make any TAB there will be "*" at the beginning.
    Here is how it looks in the table of contents where tabs are also used:
    http://img195.imageshack.us/img195/4333/screenshot20091018at214.png
    Interesting is that TABs works just in TextEdit.
    Any ideas how to get rid of "*"? By the way it shows up only on regular type, if it is bold or italic there is no any start at the beginning of TAB.
    Thanks in advance,
    david

    Hi David
    Welcome to the forum.
    There appear to be problems with Lithuanian support in MacOSX:
    http://raidynas.blogspot.com/2008/09/guidelines-for-adapting-apple-products.html
    What keyboard are you using?
    This:
    http://www.cch.kcl.ac.uk/clip2006/redist/abstracts_pdf/poster11.pdf
    …seems to suggest there are various versions of the font Palemonas and it is only a subset of the required glyphs for Lithuanian.
    I was unaware there were any characters in Lithuanian that couldn't be met by the U.S. Extended keyboard which seems to contain virtually all the exceptional European accents, but then you could no doubt correct that.
    It sounds to me like there is an error in the actual font that is in the regular face but not the bold or italic, although it is odd that it manifests itself in Pages but not TextEdit. Have you tried any other applications to test the extent of the problem, to see if it is purely Pages?
    Tom Gewecke who is the resident multi-lingual god on the Mac may be able to caste further light on this. Have a look on his site:
    http://www.freeforum101.com/iworktipsntrick/viewtopic.php?t=21&mforum=iworktipsn trick
    Peter

  • Parsing xml with dom4j - cannot find jar file

    Hi,
    I'm using Jdeveloper 10g and tomcat 5.5.9. I have a servlet which calls a java class (ParseXML.java) that trys to parse an xml string using dom4j. A snippet of ParseXML.java...
    import org.dom4j.Document;
    import org.dom4j.DocumentException;
    import org.dom4j.io.SAXReader;
    public class ParseXML  {
    public ParseXML(String xml) {
              this.XML_STRING = xml;
         public String parse() {
              SAXReader reader = new SAXReader();
              Document document = null;
              try  {
                   document = reader.read(XML_STRING);
                   } catch (DocumentException de)  {
                   return de.getMessage();
              } catch (Exception e) {
                   return e.getMessage();
                   return "The xml root value is: " + document.getRootElement().getName();
    } I've downloaded the dom4j 1.6.1 jar and put it on the project class path (specified in the jdev project proerties), and my code also compiles ok. But when i try to instantiate ParseXML from my servlet i get a runtime exception:
    javax.servlet.ServletException: Servlet execution threw an exception
    root cause
    java.lang.NoClassDefFoundError: org/dom4j/DocumentException
         arcims.GetMapServlet.doPost(GetMap.java:45)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802I'm not sure if this is a class path issue or something else; i've checked and rechecked the classpath and nothing seems amiss.
    Suggestions, anyone?

    Question: Is it really necessary to use a
    StringReader if my xml document is not saved to disk?
    I get XML_STRING from a web service, convert it into
    a xml document so i can manipulate/parse it, but then
    i don't save the document, i just discard it. How
    does my system's default character set affect string
    manipulations that i do within my java app?Your system's default charset doesn't have anything to do with string manipulations, if by that you mean substrings and concatenations of strings. It is used when you convert strings to bytes and bytes to strings. If your string contains a character that can't be handled by your default charset, then converting that string to bytes will put ? in place of that character. Converting those bytes back to a string will leave the ? as is. Thus your string has been changed.
    Also converting the string to bytes can have bad results, because the first thing the XML parser does is to convert the bytes back to a string, using the charset declared in the XML. If this charset is different from your system's default, then your XML may be corrupted by this process if it contains characters that are encoded differently in the two charsets. The typical example of this is European accented letters like �, which are encoded differently in ISO-8859-1 or Windows-1252 (most people's default charsets) and UTF-8 (the default XML charset).
    Besides, converting the string to bytes just so it can be immediately converted back to a string is rather wasteful.

  • Text messaging in other languages

    Seems like 3G does not support text messaging in Korean. Messages sent or received in Korean appears as blank or question marks. Is there going to be a firmware update in the future that will allow text messaging in foreign languages?
    Message was edited by: sleeny

    Well, it's a bit complicated, so please bear with me here!
    1. An American in the Seattle area whose Window$ PC just got upgraded so that Chinese will display on her computer - not that she can read it - got the Chinese characters from my iPhone, but the European accented letters (é, ê, è, ü etc.) as well as... quotation marks showed up as blank boxes in her reply when I read it on my iPhone. But when I read her reply in *Apple Mail*, each of those showed up as a box with a little cauldron(?) in it.
    2. A French Window$ PC / Outlook user in Paris got the same blank boxes when I read his reply on my iPhone, but when read in Entourage on my Mac, they also came through with those little cauldron(?) boxes.
    3. A (traditional) Chinese Window$ PC / Outlook Express user in Taiwan got all the foreign accented characters, quotation marks and the Chinese characters, whether I read his reply on my iPhone, in Apple Mail or in Entourage, even though the é went through as if borrowed from a different font.
    Any ideas???

  • UTF-8 DB with legacy clients - Unicode transcode

    I have a legacy application that can access single and double byte Oracle instances via SQL*net or Net8.
    However, If the DB is configured for UTF-8, can SQL*Net/Net8 transcode the UTF-8 into a local NLS setting on the client and what are the imlcations of this transcode (e.g. missing accents etc.)?
    Cheers
    Paul

    Your client code page determines what characters can be properly
    converted from UTF-8. Your NLS_LANG needs to reflect this client
    code page. So if your client supports 1252 then Western European
    accented characters can be supported. But Asian characters would
    not be displayed properly.

  • How to review implication of database character set change on PL/SQL code?

    Hi,
    We are converting WE8ISO8859P1 oracle db characterset to AL32UTF8. Before conversion, i want to check implication on PL/SQL code for byte based SQL functions.
    What all points to consider while checking implications on PL/SQL code?
    I could find 3 methods on google surfing, SUBSTRB, LENGTHB, INSTRB. What do I check if these methods are used in PL/SQL code?
    What do we check if SUBSTR and LENGTH functions are being used in PL/SQl code?
    What all other methods should I check?
    What do I check in PL/SQL if varchar and char type declarations exist in code?
    How do i check implication of database characterset change to AL32UTF8 for byte bases SQL function.
    Thanks in Advance.
    Regards,
    Rashmi

    There is no quick answer.  Generally, the problem with PL/SQL code is that once you migrate from a single-byte character set (like WE8ISO8859P1) to a multibyte character set (like AL32UTF8), you can no longer assume that one character is one byte. Traditionally, column and PL/SQL variable lengths are expressed in bytes. Therefore, the same string of Western European accented letters may no longer fit into a column or variable after migration, as it may now be longer than the old limit (2 bytes per accented letter compared to 1 byte previously). Depending on how you dealt with column lengths during the migration, for example, if you migrated them to character length semantics, and depending on how relevant columns were declared (%TYPE vs explicit size), you may need to adjust maximum lengths of variables to accommodate longer strings.
    The use of SUBSTR, INSTR, and LENGTH and their byte equivalents needs to be reviewed. You need to understand what the functions are used for. If the SUBSTR function is used to truncate a string to a maximum length of a variable, you may need to change it to SUBSTRB, if the variable's length constraint is still declared in bytes.  However, if the variable's maximum length is now expressed in characters, SUBSTR needs to be used.  However, if SUBSTR is used to extract a functional part of a string (e.g. during parsing), possibly based on result from INSTR, then you should use SUBSTR and INSTR independently of the database character set -- characters matter here, not bytes. On the other hand, if SUBSTR is used to extract a field in a SQL*Loader-like fixed-format input file (e.g. read with UTL_FILE), you may need to standardize on SUBSTRB to make sure that fields are extracted correctly based on defined byte boundaries.
    As you see, there is universal recipe on handling these functions. Their use needs to be reviewed and understood and it should be decided if they are fine as-is or if they need to be replaced with other forms.
    Thanks,
    Sergiusz

  • Character encoding with cfntauthenticate

    I've been authenticating users of my web app against Active Directory using the cfntauthenticate tag which works pretty well and was simple to implement.  We have one or two European users who cannot log in because they are getting an invalid password error.  There username and password was checked as being valid by using other non-CFapplications that also authenticate against the domain .  The common thread seems to be that they use umlauted or other European accented characters.  These characters can be multi-byte in a unicode environment so I've tried a number of methods to altering the encoding of the page so that the password is recognized as valid but have had no luck so far.  Has anyone encountered this or have any information on the encoding of the form field when passing it through this tag? 
    Brian

    I don't have an answer for your issue, but I'm surprised that it works at all.  The docs for cfntauthenticate (at least the ColdFusion 10/11 docs) specifically say that it won't work with Active Directory, only with a Windows NT domain.  You might have better luck using CFLDAP.
    -Carl V.

  • MacBook Air and Harmony Remote

    I recently purchased a Harmony 900 remote and am trying to configure it on my MacBook air. Harmony admits that there are communication problems with their remotes and Snow Leopard Mac.
    Their work around is to go to network settings and specifically configure the USB port by changing it to Ethernet Adaptor.
    However I cannot do this since the MBA only as a USB Ethernet.
    I can post the Link to Harmony's FAQ if it helps.
    Any suggestions are appreciated.
    thanks

    I'm having the same problem with my Air, Harmony 900, and Snow Leopard.
    Supposedly Logitech's top Mac tier II support person, guy with a Russian/Eastern European accent, couldn't figure it out and said he was going to speak with the product specialist about it. That was over a month ago and I never heard back from Logitech.
    I'm on hold with them right now again. I've already spent several hours trying to troubleshoot the problem.

  • Problem with m3u playlists where sme files have special characters

    This may be an OS X question but it only comes up inside iTunes, so hopefully someone here can help me.
    I have brought over from my old (Windows) computer a large set of mp3 files, with m3u files for each album. In many cases, the file name contained European accented characters, such as "Gété" or "Köln". When I pull the m3u file into iTunes, it simply ignores these entries!
    I have no problem playing these files or putting them in new playlists. But this means that I have now to look manually at each m3u and see if it needs fixing. If I knew what the correct encoding needs to be then I can easily write a Python script to fix the m3u's, or even, if necessary, rename the files. But so far I haven't figured out what would work.
    Any ideas?
    Thanks,

    I am having the exact problem. Did you ever find a solution?

  • Re: APPALLING CUSTOMER SERVICE FROM PAYPAL - COMPLAINTS TOTALLY IGNORED!!

    There is no customer service at Paypal. From July 10, 2015 to Juky 13, 2015 I tried to move money from my Paypal account to my Paypal Debit MasterCard on my online Paypal site. It simply does not work. The money was sent on Thursday night, July 9, 2015. I tried to put it on my card from around 10 am till about 5:00pm on July 10. Each time I went through the process to link the two accounts I received this message: "An unknown service error occurred. On Monday, July 13, 2015, I tried again and the same thing occurred. After calling customer service about fice (5) times i finally got a person who was a native English speaker. This is only important because the technology and number of times that one is told to hold on for a moment makes trying to talk to someone that you cannot understand doubly frustrating. Whenever I did get someone on the phone I could not hear them and they could not hear me. It was like we were using a phone system from the 1920's. The volume was intermittent at best and like talking on string with cans at worst. On the last call I spoke to 2 men. The first guy talked to me for a while as we both screamed "Can you hear me? Can you hear me? What did you say?" Finally he said he was going to connect me with someone who could help, but he never came back. An automaton with a woman's voice came on the line and asked question after question but I could hardly hear her. But I held on the line. Finally a man with a foreign European accent came on the line and we played the same "I can't hear you" game for about 20 to 30 minutes. Whenever he talked, I could hear his voice, but I could not understand a word he was saying. I begged him to simply hang up and call me back so that the lines would not be hampered by so many connections. I think the many connections and data one has to enter to speak to a person is what reduced the volume. So Paypal has my money and I can't get it. And whatever I do to get my money is blocked or digitally and electronically frozen to stop me in my tracks. And all of the five to seven people that I have talked to at PayPal and PayPal Debit MasterCard are too busy to help me get my money. Public please beware of this company.     

    Have you considered contacting Customer Service via Facebook or Twitter?
    You can send them a personal message from their facebook or twitter pages.
    It's: https://www.facebook.com/PayPal and @AskPayPal for Twitter.

  • Some applications don't put accents with non-english keyboard layouts

    I'm using a Portuguese keyboard with three different macs running Mac OS Tiger 10.4.8/9. Some applications (like Motion 2 and Swift Publishing 2) don't allow writing some accented characters, like (è) or (ê), that are accessed by Shift+normal key, but they do display correctly other accented letters, for instance (é), witch are accessed directly without the Shift key. This happens only in some applications and with a european keyboard layout (I tried it also with the spanish and french keyboards layouts), but not with other applications (it works all right with Word or iPhoto) and the english keyboards.
    Any sugestion as how to solve this? If I create the text in some other application and paste it in Motion it works! But it's a drag.
    iMac Core2Duo 20" Mac OS X (10.4.8) MacBook Core2Duo MacPlus

    Hey KDCruz,
    Thanks for the question. Let's see if we can isolate the issue further, the following article has some great troubleshooting steps:
    One or more keys on the keyboard do not respond
    http://support.apple.com/kb/TS1381
    Thanks,
    Matt M.

  • Flat-File MA accented character conversion

    Hello, we are using FIM 2010 R2 SP1 (4.1.3599) with a flat file MA to import/sync a csv flat-file generated by a HR system. We are using UTF-8 code page. The HR system has many international people in it, so there are many accented or diacritic characters. 
    We need to convert those to regular English non-accented equivalents.  I know we could write sync rule or rules extension code to do this. However, there is an option on the select attributes properties page, under advanced a checkbox that says "Replace
    accented characters with non-accented variants", which looked like an easy way to fix this issue.  However, enabling that option does not seem to change anything during the import/sync process.  Has anyone had any success
    using that option, and is there anything we are missing?

    We tried multiple code pages in the HR ma, including multiple Latin variations (don't see anything specifically called ISO-8859-1).  However, none of them showed the various characters correctly except for UTF-8.  We were getting a lot of bad
    conversion characters (like tm and copywright) using the other code pages.  The names are very global with multiple character sets involved (Middle Eastern, Asian and European).   

  • Can't use a circumflex accent in iCal

    I'm trying to add French public holidays to a UK calendar, using Apple's own calendar for this. The French for Easter is Pâques, but in my iCal calendar it comes out as Pâques. It's possible to get it right by using the Character Palette in Tiger to paste the letter in. Similarly, the French for Pentecost is Pentecôte, but this comes out as Pentecôte, and Fête comes out as Fête. Note that the incorrect versions are all different! I have not tried to test this for other European languages.
    I've noticed a similary problem with text in iPhoto. Surely this can't happen in France! I have no difficulty typing accented words in say TextEdit, so it isn't a universal problem. Can anyone explain how to fix this?
    iMac G5, 1Gb RAM (UK); Intel Mini, 1.25Gb; B & W G3/400 (France)   Mac OS X (10.4.8)   Canon digital cameras, iSight cameras

    Odd thing is happening in iCal when creating a new event, clicking on the plus button creates a new calendar and not an event.
    This is normal. You can create a new event by double-clicking within the day in any of the views (in Day or Week view double-click on the time for the event): select the calendar you want to add to in the sidebar first.

  • Sms with accented characters

    Hi,
    I hope somebody with some SMS/SMPP experience would be able to fix the problem or
    advise as what to do. OK Now we have an application which is supposed to send an
    SMS to a recipient on certain occassions and this SMS might contain accented characters.
    Now in SMPP apparently we have three encoding schemes namely
    1) 7 bit GSM encoding
    2) 8 bit binary
    3) UCS-2
    Now the third one is out of question since it would reduce the size of the message
    to 70 characters which is not acceptable. 2nd one which is 8 bit binary with I assume
    DCS value 4(or at least thats what we are using) seems to support only latin characters.
    It works for latin characters i.e., iso-8859-1 which does have some accented characters.
    however for other than latin we have some problems e.g hex value for small phi in
    greek (iso-8859-7) is f6. If you look at the corresponding value of f6 in Latin 1(iso-8859-1)
    it is �. Now if you send greek characters setting the DCS value to 4 and u send three
    phi's what you would recieve on the recipient device are three �. So it seems that
    the 8 bit binary supports only iso-8859-1.
    Now if I try to do some encoding into GSM 7 bit. and send three phi's thought I dont
    recieve � but not phi's at the recieving end. The DCS value for the purpose I am
    using is 0. How am I encoding it to GSM 7 bit.
    I am creating the following array
    private static final char [] GSM_7Bit_CHARACTERS = {
    '@', '\243', '$', '\245', '\350', '\351', '\371', '\354', '\362', '\307',
    '\n', '\330', '\370', '\r', '\305', '\345', '\u0394', '_', '\u03A6', '\u0393',
    '\u039B', '\u03A9', '\u03A0', '\u03A8', '\u03A3', '\u0398', '\u039E', '\033',
    '\306', '\346',
    '\337', '\311', ' ', '!', '"', '#', '\244', '%', '&', '\'',
    '(', ')', '*', '+', ',', '-', '.', '/', '0', '1',
    '2', '3', '4', '5', '6', '7', '8', '9', ':', ';',
    '<', '=', '>', '?', '\241', 'A', 'B', 'C', 'D', 'E',
    'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
    'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y',
    'Z', '\304', '\326', '\321', '\334', '\247', '\277', 'a', 'b', 'c',
    'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm',
    'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
    'x', 'y', 'z', '\344', '\366', '\361', '\374', '\340'
    Storing all the values in a Map in teh same order and then for each character in the
    message sending the byte value of the index. If I do a snoop in the snoop I see the
    right hex values as per GSM Encoding table but on the recipient device I see garbage.
    Any ideas as to how can greek and other european character set support be added to
    this application?
    Am I using the wrong DCS value or any body with some other ideas.

    I don't know about the exact character sets for the 7 and 8-bit SMS, but I doubt it's any different then character sets for anything else... So, in this case, the 7-bit set will only be able to handle the first 128 chars, which is A-Za-z0-9 and some punctuation. 8-bit would go into the extended ASCII chars in the table here:
    http://www.asciitable.com/
    There might be some restrictions or differences.
    Basically, 7-bit is ASCII. 8-bit is ASCII+Extended or ISO8895-1. The chars your talking about sending get into the other ISO8895-X sets, which I believe would be out of range. The USC-2 should give you these, however. So either you send shorter messages, or you send ASCII text.
    It would also depeend on the device to be able to display those characters in the first place. Just like on any web site, if you don't have a font that has the necessary characters, it just displays as ? or a box or whatever.

Maybe you are looking for

  • P55 CD-53 Memory mixing supported

    Is it possible to mix 2 different speed DDR3 kits ? Somthing like this: DIMM1 & 3: 1333 MHz 9-9-9-24 DIMM2 & 4: 1066MHz 7-7-7-20

  • How to extend a VO:add attribute with funcation with parameters.

    Need to extend a VO by adding an attribute (newVOAttribute1) which will be fed via a plsql function (function.get_data(oldVOAttribute1...)). The function parameters (oldVOAttribute1...) will be from the attributes of the original VO (oldVOAttribute1.

  • Safari 6.1.5 keeps crashing

    Hello, I tried deleting its cache but it kept crashing and also I tested a separate account in the mac and it does the same. I am running mountain lion 10.8.5 on a Mac book pro late 2012 13inches. any help will be appreciated! Process:         Safari

  • How to add idocs to SLD? File adapter resend file? List of idocs?

    Hi Everybody,             Can someone pls help me find answers to the following: 1) If i need to use idocs in my integration scenario, how do i specify them in my sld? 2) Also in file adapter the incoming file is stored in a directory. If the file is

  • Is there a limit on cover art and if so, can I extend that limit?

    I finally got around to adding cover art today and things were going great. Itunes supplied most of the art and the rest I was copy/pasting from Amazon and similar sites. However, just as I was about 10 albums away from being done, I can no longer pa