Open web page from dialog

Jan Rheinländer jrheinlaender at
Sun Jun 12 17:36:14 UTC 2016

Hi Fernand,

thank you for the tip with UnoControlFixedHyperlinkModel. Now this is
what I have:

Reference<XDialog> xDialog; // Created from XDialogProvider somewhere
earlier in the code

First question: How do I get a MultiServiceFactory from XDialog to
create the control? If I use the MultiComponentFactory the properties
like "PositionX" etc. are not present

Now assuming I get this MultiServiceFactory from somewhere:

Reference< XPropertySet >
xPSHyperlink->setPropertyValue("PositionX", makeAny(50));
xPSHyperlink->setPropertyValue("PositionY", makeAny(30));
xPSHyperlink->setPropertyValue("Width", makeAny(50));
xPSHyperlink->setPropertyValue("Height", makeAny(14));
xPSHyperlink->setPropertyValue("Label", makeAny(OU("Help")));

Second question: How do I get a XControl from the
UnoControlFixedHyperlinkModel  to add to the ControlContainer?

Reference< XControlContainer > xControlContainer(xDialog, UNO_QUERY_THROW);
xControlContainer->addControl(OU("button_help"), xHyperlinkControl);

I have looked all over the UNO API but am not getting anywhere.


> oDialogModel.createInstance( 
> "")

> On Jun 11, 2016, at 3:24 PM, "Jan Rheinländer" <jrheinlaender at
> <mailto:jrheinlaender at>> wrote:
>     Hi,
>     is it possible to open a website in the user's preferred browser from a
>     dialog (or from a Basic macro, or through the UNO API)?
>     I see that the "Help" - "About" dialog does this, but it is defined in
>     the source in Glade format, different to the Basic dialogs.
>     Thanks for any ideas!
>     Jan
>     ------------------------------------------------------------------------
>     LibreOffice mailing list
>     LibreOffice at
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the LibreOffice mailing list