Hello, I would like to know if someone could help me with a macro. In my work I export many images, and I use the macro to export all pages. I have a file with 900 images to export but they ask me to add a line around the image, they are all of different sizes. I would like to know if someone can help me with a macro to be able to add a rectangle to all the pages with its corresponding size. please and thanks in advanceDim s1 As ShapeSet s1 = ActiveLayer.CreateRectangle(0#, 11#, 8.5, 0#)s1.Rectangle.CornerType = cdrCornerTypeRounds1.Rectangle.RelativeCornerScaling = Trues1.Fill.ApplyNoFills1.Outline.SetPropertiesEx 0.010417, OutlineStyles(0), CreateCMYKColor(0, 0, 0, 50), ArrowHeads(0), ArrowHeads(0), cdrFalse, cdrFalse, cdrOutlineButtLineCaps, cdrOutlineMiterLineJoin, 0#, 100, MiterLimit:=5#, Justification:=cdrOutlineJustificationMiddleEnd SubI have this, but i dont know how to put to change depending of the size of each page
After hours searching I finally made it myselfSub RectToPaperSimple() Dim p As Page, s As Shape, sr As ShapeRange Dim i& For i = 1 To ActiveDocument.Pages.Count ActiveDocument.Pages(i).Activate With ActiveLayer.Page ActiveLayer.CreateRectangle .LeftX, .TopY, .RightX, .BottomY End With Next i ActiveDocument.Pages(1).ActivateEnd Sub