+ Reply to Thread
Results 1 to 2 of 2

Change Text on Form Control Button with VBA

  1. #1
    Forum Contributor
    Join Date
    02-24-2011
    Location
    Los Angeles, CA
    MS-Off Ver
    Office 2010
    Posts
    164

    Change Text on Form Control Button with VBA

    Okay, hopefully I'll explain this correctly so it makes sense.

    Sheet1 is named "Home Page", and on here I have 15 different form control buttons that are set up to filter my main set of data on Sheet2 "Division IDPs". These macros work fine. (Don't ask, I needed a template for a bunch of groups/divisions that can't do basic filtering in Excel.)

    The problem I'm having is that on Sheet3 "Rep List" I have a list of names in the range of K2:K16. I'm trying to set it up using VBA to change the text on the 15 form control button.

    The 15 buttons are named "DivRep1" thru "DivRep15 to correspond with the range K2:K16.

    I'll wind up having about 20 different files for all the different divisions and trying not to have to manually change the text on each of the buttons.

    Any help would be greatly appreciated.

    Thanks.

  2. #2
    Forum Contributor
    Join Date
    02-24-2011
    Location
    Los Angeles, CA
    MS-Off Ver
    Office 2010
    Posts
    164

    Re: Change Text on Form Control Button with VBA

    Got it...

    Sheets(1).Shapes("DivRep1").TextFrame.Characters.Text = Range("K2")
    Sheets(1).Shapes("DivRep2").TextFrame.Characters.Text = Range("K3")
    Sheets(1).Shapes("DivRep3").TextFrame.Characters.Text = Range("K4")

    etc...

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Change the text color of a form button in Excel Mac 2011?!
    By RiTz21 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 01-09-2014, 06:25 PM
  2. Have checkbox change properties of spin button (form control)
    By spookymyo in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 01-19-2013, 04:19 AM
  3. Hide a picture button placed in all sheets using a option button (form control)
    By lagaranch in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 12-26-2012, 10:33 AM
  4. ActveX Control Button Not Working But Form Control Button is
    By MikeTruth in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 05-31-2012, 05:04 AM
  5. Sorting Button (form control) alphabetically based on text label
    By DTK in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 08-30-2010, 08:48 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1