Apache OpenOffice (AOO) Bugzilla – Issue 75422
macro Recorder does not repeat results of the recording
Last modified: 2008-05-30 11:40:45 UTC
I want to produce a frame 15 cm wide with no border. The macro below does exactly what I want during the recording. However, when running the macro, the frame always has a border. The results have been replicated by exactt, another forum user. Here are the steps: 1) Tools > Macros > Record Macro 2) Insert > Frame 3) In the Type tab, enter 15 for width. 4) In the Borders tab, select None in Line Style 5) Click OK. The correct frame is produced. 6) Click Stop Recording Here is the macro: rem ---------------------------------------------------------------------- sub InsertFrame 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 ---------------------------------------------------------------------- dim args1(4) as new com.sun.star.beans.PropertyValue args1(0).Name = "AnchorType" args1(0).Value = 0 args1(1).Name = "Pos.X" args1(1).Value = 0 args1(2).Name = "Pos.Y" args1(2).Value = 0 args1(3).Name = "Size.Width" args1(3).Value = 15000 args1(4).Name = "Size.Height" args1(4).Value = 499 dispatcher.executeDispatch(document, ".uno:InsertFrame", "", 0, args1()) end sub
Reassigned to JSK.
Confirming with 2.2 RC2. Issue http://www.openoffice.org/issues/show_bug.cgi?id=68515 seems to be related.
Dupe to - yes, just one more of these macro recorder things that do not work... *** This issue has been marked as a duplicate of 20046 ***
close