To comment on the following update, log in, then open the issue:
http://www.openoffice.org/issues/show_bug.cgi?id=75422
                 Issue #|75422
                 Summary|Recorded macro does not repeat results of the recordin
                        |g
               Component|Word processor
                 Version|OOo 2.1
                Platform|All
                     URL|
              OS/Version|All
                  Status|UNCONFIRMED
       Status whiteboard|
                Keywords|
              Resolution|
              Issue type|DEFECT
                Priority|P3
            Subcomponent|programming
             Assigned to|mru
             Reported by|alandavidson





------- Additional comments from [EMAIL PROTECTED] Thu Mar 15 10:51:03 +0000 
2007 -------
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

---------------------------------------------------------------------
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]

Reply via email to