Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Calc macro, how to find the address of a seelcted cell?

I have this code:

Blockquote sub Main rem ---------------------------------------------------------------------- rem define variables dim document as object dim oSel as object, oSheet as object rem ---------------------------------------------------------------------- rem get access to the document oSheet=thiscomponent.getcurrentcontroller.activesheet oSel = ThisComponent.getCurrentSelection() print oSel.value end sub

How do get the address of oSel in eg "$H$6" format so I can paste data in that cell which I copied from another cell in a fixed location?

Calc macro, how to find the address of a seelcted selected cell?

I have this code:

Blockquote

sub Main
 rem ----------------------------------------------------------------------
 rem define variables
 dim document   as object
 dim oSel as object, oSheet as object
 rem ----------------------------------------------------------------------
 rem get access to the document
 oSheet=thiscomponent.getcurrentcontroller.activesheet
 oSel = ThisComponent.getCurrentSelection()
 print oSel.value
 end sub

sub

How do get the address of oSel in eg "$H$6" format so I can paste data in that cell which I copied from another cell in a fixed location?