Skip to main content

Search

Search

Assign an object reference to a variable [Solved]

Comments

1 comment

  • Avatar
    Matthew Baker

    Solved using the Set keyword

    Dim graphicItems(3)
    Set graphicItems(0) = Format.Objects("Graphic 1")
    Set graphicItems(1) = Format.Objects("Graphic 2")
    Set graphicItems(2) = Format.Objects("Graphic 3")
    Set graphicItems(3) = Format.Objects("Graphic 4")

    For Each item In graphicItems
        item.Width = 3.5
        item.Height = 3.5
        item.X = 0.0
    Next

    0

Please sign in to leave a comment.