Hyperlink run macro

Creating a macro - Writing a Script - Using the API (OpenOffice Basic, Python, BeanShell, JavaScript)
Post Reply
clag
Posts: 62
Joined: Thu Apr 23, 2015 8:12 pm

Hyperlink run macro

Post by clag »

Hello to all,

in a Writer dokument I want reconfigure with a macro, normal hyperlinks which start a URL to hyperlinks which start a marco.
When new hyperlink is clicked and the macro is called, the hyperlink text should be parameter for the called macro.

I find here a likely question, but I am not able to bring the example code to run.
viewtopic.php?f=45&t=53609

There are two questions
1. how to reconfigure an existing hyperlink that click start a macro?
2. how to make the hyperlink text to a parameter for the called makro?

thanks ahead
clag
OpenOffice 4.1.2 on WINDOWS XP SP3
User avatar
Villeroy
Volunteer
Posts: 31348
Joined: Mon Oct 08, 2007 1:35 am
Location: Germany

Re: Hyperlink run macro

Post by Villeroy »

clag wrote:1. how to reconfigure an existing hyperlink that click start a macro?
Enter another hyperlink in cell A2 or enter more hyperlinks below A2 and copy down the formula in B2.
clag wrote:2. how to make the hyperlink text to a parameter for the called makro?
This is what the demo file tries to demonstrate.

Important note: LibreOffice lost the ability to call macros by URL protocol vnd.sun.star.script:
The feature is back again in LO 5.2
Last edited by Villeroy on Tue Nov 22, 2016 5:01 pm, edited 1 time in total.
Please, edit this topic's initial post and add "[Solved]" to the subject line if your problem has been solved.
Ubuntu 18.04 with LibreOffice 6.0, latest OpenOffice and LibreOffice
lodovi
Posts: 15
Joined: Fri May 13, 2016 2:23 pm

Re: Hyperlink run macro

Post by lodovi »

Hello, is some similar solution as hyperlink to run macro also for LibreOffice? Or is it posible only with button?
LibreOffice 5.2.2.2. OS Win 7
User avatar
Villeroy
Volunteer
Posts: 31348
Joined: Mon Oct 08, 2007 1:35 am
Location: Germany

Re: Hyperlink run macro

Post by Villeroy »

lodovi wrote:Hello, is some similar solution as hyperlink to run macro also for LibreOffice? Or is it posible only with button?
The feature is back again in LO 5.2.
Please, edit this topic's initial post and add "[Solved]" to the subject line if your problem has been solved.
Ubuntu 18.04 with LibreOffice 6.0, latest OpenOffice and LibreOffice
lodovi
Posts: 15
Joined: Fri May 13, 2016 2:23 pm

Re: Hyperlink run macro

Post by lodovi »

Thank you for information. Realy after upgrade it is worked now. Super.
LibreOffice 5.2.2.2. OS Win 7
Post Reply