To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=97725 Issue #|97725 Summary|Error in recorded macro when lines round cells are def |ined Component|Spreadsheet Version|OOO300m9 Platform|HP URL| OS/Version|Windows XP Status|UNCONFIRMED Status whiteboard| Keywords| Resolution| Issue type|DEFECT Priority|P3 Subcomponent|editing Assigned to|spreadsheet Reported by|priccen
------- Additional comments from [email protected] Sat Jan 3 13:46:33 +0000 2009 ------- I am trying to record a macro to define lines in a bunch of cells. eg: I choose B4 - D13. I do: Record macro Format > Cells Define lines (In Swedish "Inramning" (I use Swedish)) I define 0.5-lines at every place OK Stop recording macro. Saving the macro in my lib The result on my screen is just as I wanted: a grid net round each cell I choose an other bunch of cells and run my recorded macro. Nothing happens My recorded macro looks like: Sub Main End Sub sub Cell_lines 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(7) as new com.sun.star.beans.PropertyValue args1(0).Name = "BorderOuter.LeftBorder" args1(0).Value = Array(0,0,18,0) args1(1).Name = "BorderOuter.LeftDistance" args1(1).Value = 0 args1(2).Name = "BorderOuter.RightBorder" args1(2).Value = Array(0,0,18,0) args1(3).Name = "BorderOuter.RightDistance" args1(3).Value = 0 args1(4).Name = "BorderOuter.TopBorder" args1(4).Value = Array(0,0,18,0) args1(5).Name = "BorderOuter.TopDistance" args1(5).Value = 0 args1(6).Name = "BorderOuter.BottomBorder" args1(6).Value = Array(0,0,18,0) args1(7).Name = "BorderOuter.BottomDistance" args1(7).Value = 0 dispatcher.executeDispatch(document, ".uno:BorderOuter", "", 0, args1()) rem ---------------------------------------------------------------------- dim args2(4) as new com.sun.star.beans.PropertyValue args2(0).Name = "BorderInner.Horizontal" args2(0).Value = Array(0,0,18,0) args2(1).Name = "BorderInner.Vertical" args2(1).Value = Array(0,0,18,0) args2(2).Name = "BorderInner.Flags" args2(2).Value = 3 args2(3).Name = "BorderInner.ValidFlags" args2(3).Value = 127 args2(4).Name = "BorderInner.DefaultDistance" args2(4).Value = 0 dispatcher.executeDispatch(document, ".uno:BorderInner", "", 0, args2()) end sub If I define only outer lines, lines round my chosen cells or background color I got a working macro. --------------------------------------------------------------------- Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
