Stefan Weigel wrote:

> Hi all,
> 
> I would like to be able to start some macro when the user clicks a
> cell in calc. Could someone give me a hint, how to create a listener
> for a kind of a MouseUp event?
> 
> I have already working a ModyfyListener like that:
> 
> ...
> oListener = CreateUnoListener( "Change_",
> "com.sun.star.util.XModifyListener" )
> oCell1.addModifyListener( oListener )
> ...
> 
> Sub Change_modified( aEvent )
>     msgbox "cell modified"
> End Sub
> 
> I guess there should be a similar approach to react to a mouseclick.

You can try to use the com.sun.star.awt.UserInputInteraction interface
that is available at the Controller object of a Calc document window.
The problem here might be that this interface only notifies that a mouse
click has happened anywhere inside the window, you still must find out
where exactly that has happened. I don't know if Calc meanwhile has a
specialized API for things like that.

Ciao,
Mathias


-- 
Mathias Bauer (mba) - Project Lead OpenOffice.org Writer
OpenOffice.org Engineering at Sun: http://blogs.sun.com/GullFOSS
Please don't reply to "[EMAIL PROTECTED]".
I use it for the OOo lists and only rarely read other mails sent to it.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to