Hi Rainman,

On Thursday, 2008-06-19 16:13:01 +0800, Rainman Lee wrote:

> [...]
>         Reference<XInterface> xInterface =
> xMultiFactory.get()->createInstanceWithContext(L"com.sun.star.awt.Toolkit",
> m_xContext);
> [...]
> when the component is runing, it shows the first two message boxes as
> expected, and crashes without showing the last one.

I'm almost certain that L"some string" is the culprit, because the
method expects a rtl::OUString there. Use
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.awt.Toolkit"))
instead.

However, that would not explain why that

> but if I replace "com.sun.star.awt.Toolkit" with
> "com.sun.star.awt.UnoButtonModel" or
> "com.sun.star.awt.ContainerWindowProvider" instead, it runs correctly with
> all message boxes displayed.

works, but I guess it just does not crash by accident because of
different memory layout.

  Eike

-- 
 OOo/SO Calc core developer. Number formatter stricken i18n transpositionizer.
 SunSign   0x87F8D412 : 2F58 5236 DB02 F335 8304  7D6C 65C9 F9B5 87F8 D412
 OpenOffice.org Engineering at Sun: http://blogs.sun.com/GullFOSS
 Please don't send personal mail to the [EMAIL PROTECTED] account, which I use 
for
 mailing lists only and don't read from outside Sun. Use [EMAIL PROTECTED] 
Thanks.

Attachment: pgpZNMgxrz7Tw.pgp
Description: PGP signature

Reply via email to