I can make the checkbox, no problem there.
To ad the macro function, I've found some code that can make a button run a macro when pressed.
Trying to alter this code, to fit my needs is where I ran into trouble, I tried to use MRI to help me, but either MRI can't do what I need, or I don't know how to get MRI to do it.
The value for EventMethod are my problem, "MouseButtonPressed" isn't a valid value, I had hoped MRI could give me a list of valid options, but if it can, I don't know how.
Anyone who have an idea to how to get the valid options ?
Code: Select all
aEvent = CreateUnoStruct("com.sun.star.script.ScriptEventDescriptor")
With aEvent
.AddListenerParam = ""
.EventMethod = "MouseButtonPressed"
oMri.inspect(aEvent)
.ListenerType = "XActionListener"
.ScriptCode = sScriptURL
.ScriptType = "Script"
End With