Announcement

Collapse
No announcement yet.

Change Button Caption Code

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Change Button Caption Code



    Split off from: http://www.ozgrid.com/forum/showthread.php?t=73924

    That's great the
    Code:
    Sheets("Name").Shapes("objName").ControlFormat.Enabled=FALSE
    works brilliantly.

    However, using that method, I can't alter the Caption of the buttons, any idea of a way to do this?

    Thanks
    James
    Last edited by Dave Hawley; July 31st, 2007, 18:07.

  • #2
    Re: Change Button Caption Code

    James, please use code tags for any code and always start a New Thread when your question no longer matches the Thread Title. I have done both for you, but please take more care and read the text you are shown when posting.

    Code:
    Sheet1.Shapes("Button 1").TextFrame.Characters.Text = "Click Me!"

    Comment


    • #3


      Re: Change Button Caption Code

      Another approach.
      Code:
      Set o = Worksheets("Sheet1").Shapes("Button 1")
      o.OLEFormat.Object.Caption = "New Caption"
      Boo!

      Comment

      Working...
      X