WIndows does not have a code page for UTF-8. If you want to display UTF-8,
you have either send UTF-16 to the 'W' API or convert to some local code
page.

On Fri, Mar 7, 2008 at 2:54 AM, mr.andersen <[EMAIL PROTECTED]> wrote:

>
>
> Problem found and solved!
>
> First of all - thanks for the quick responses.
>
> I have looked more into kode and the bytes written to my log.
> And I can conclude that there is no problem with SAAJ (which would wonder
> me) or CXF.
> The problem lays in the way bytes are presented onscreen, when nordic
> characters are displayed.
>
> Maybe I should start to tell more about the environment i'm working in:
>
> Windows (danish XP version)
> RAD 7, which by the way uses cp1252 as encoding in the projects)
> IBM MQ
>
>
> As you proberly know nordic characters is presented as 2 bytes in UTF-8 -
> for example is &aring; -> C3 A5.
> When the that character is written onscreen or I use Wordpad, the cp1252
> is
> taking over and the "translation" is &Atilde;&yen;. But if you use
> ultraedit
> to see which bytes (short cut: ctrl+h) it is, it's okay.
>
> So where is the problem? Well the problem lays in the way IBM have
> implemented javax.jms.TextMesage. It seams like when a TextMessage is
> created the dobbelt bytes are converted into dobbelt bytes. So &Atilde; is
> converted to C3 A0 and &yen; C2 A5.
>
> So the way to solve this is using ByteMessage and luckily CXF gives a way
> to
> set the runtime policy in the WSDL (&lt;jms:runtimePolicy
> messageType="binary"/&gt;)
> The problem here is that doesn't work in CXF 2.0.1, so I had to take out
> the
> conduit and set the messageType by myself.
>
>
> JMSConduit conduit = (JMSConduit)client.getConduit();
> conduit.getRuntimePolicy().setMessageType(MessageFormatType.BINARY);
>
>
>
> --
> View this message in context:
> http://www.nabble.com/Nordic-charaters-problem-in-SOAP-MQ-tp15845741p15891076.html
> Sent from the cxf-user mailing list archive at Nabble.com.
>

Reply via email to