BreadCrumbs: CorelDraw

CorelDraw

From Luke Jackson

(Difference between revisions)
Jump to: navigation, search
Revision as of 01:03, 5 April 2007 (edit)
Ljackson (Talk | contribs)
(Center Shapes and Crop Document)
← Previous diff
Revision as of 01:04, 5 April 2007 (edit)
Ljackson (Talk | contribs)
(Tags)
Next diff →
Line 24: Line 24:
= Tags = = Tags =
-Visual Basic Script, Visual Basic Macro, CorelDraw11+Visual Basic Script, Visual Basic Macro, Corel Draw
[[Category:Windows XP]] [[Category:Windows XP]]

Revision as of 01:04, 5 April 2007

Macros

Center Shapes and Crop Document

Sub AutoCenterObject()
    ActivePage.Shapes.All.Group
    ActivePage.Shapes(1).CreateSelection
    Dim width As Double, height As Double
        ActiveDocument.Unit = cdrInch
        ' Add 0.05in margin
        width = ActiveShape.SizeWidth + 0.05
        height = ActiveShape.SizeHeight + 0.05
    ' Set current page size
    ActivePage.SetSize width, height
    ' Set default document page size
    ActiveDocument.Pages(0).SetSize width, height
    CorelScript.AlignToCenterOfPage 3, 3
    ActivePage.Shapes.All.UngroupAll
    ActiveDocument.ClearSelection
End Sub

Tags

Visual Basic Script, Visual Basic Macro, Corel Draw

Personal tools