Apache OpenOffice (AOO) Bugzilla – Issue 68515
Calc - Subtotals can't be automated with the macro
Last modified: 2013-08-07 15:12:27 UTC
If I include calculation of subtotals in macro, execution of macro stops displaying Subtotals dialog. Repro steps - open attached file, agree to Enable Macros, click Tools, Macros, Run, expand "macro-with-subtotals"\Standard\Module1, in "Macro Name" select "Main" and click Run. It will not run to copletion. Please make it so that Subtotals can be inserted with macro. Thanks a lot!
Created attachment 38434 [details] example file for the issue
I managed to look at the macro: I don't think this is what you want: REM ***** BASIC ***** sub Main 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 ---------------------------------------------------------------------- dispatcher.executeDispatch(document, ".uno:DataSubTotals", "", 0, Array()) end sub I will confirm that the macro does not work. James M.
So what you really want, is that the dispatch will accept arguments containing all of the information required to create the subtotal without opening a dialog or requiring any sort of user interaction. Realize that at the moment, the macro recorder noticed that you opened the dialog, but it does not record what you do in the dialog.
pitonyak, you are absolutely correct. Somebody have changed to RFE already.
one for requirements