I'm pretty new to macros (and OO in general), but I'm getting there. I've figured out how to add custom operations to a toolbar by using the macro recorder and so far so good. But....I defined a section I want to hide and unhide with a toolbar button. When I record the operation Format/Sections..., pick my section name of interest and uncheck hide what gets recorded is:
Code: Select all
sub ShowRevHistory
rem ----------------------------------------------------------------------
rem define variables
dim document as object
dim dispatcher as object
rem ----------------------------------------------------------------------
rem get access to the document
document = ThisComponent.CurrentController.Frame
dispatcher = createUnoService("com.sun.star.frame.DispatchHelper")
rem ----------------------------------------------------------------------
rem dispatcher.executeDispatch(document, ".uno:EditRegion", "", 0, Array())
Thanks!
Al