+ Reply to Thread
Results 1 to 1 of 1

How to copy an ActiveX control button to another sheet and keep the name of the button

  1. #1
    Forum Contributor
    Join Date
    05-30-2011
    Location
    Sweden
    MS-Off Ver
    Excel 2013
    Posts
    107

    How to copy an ActiveX control button to another sheet and keep the name of the button

    I have tried the code below to copy an ActiveX command button from one sheet and paste it into another:

    Sheets("SRC").HasACustomName.Copy
    Sheets("TRGT").Range("O1").PasteSpecial

    I've also tried:

    Sheets("SRC").Shapes("hasACustomName").Copy
    Sheets("TRGT").Range("O1").Select
    Sheets("TRGT").Paste

    But the problem I have with both of these is that they rename the Command button from hasACustomName to CommandButtonX.

    Can you figure out an alternative method for pasting a command button from one sheet to another that let's me retain the original name of the Command button?
    Last edited by OldManExcellor; 08-29-2013 at 05:31 AM.

+ 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. [SOLVED] VBA Code to have a repeating form control /Active X control (List box) in every row
    By Ehezve in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 08-28-2013, 08:55 PM
  2. VBA Copy row into new worksheet based on Control Form Check Box
    By carlosriver24 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 03-06-2013, 10:42 PM
  3. Form Control or ActiveX control?
    By mcctrader in forum Excel General
    Replies: 0
    Last Post: 08-22-2012, 10:52 AM
  4. [SOLVED] Hiding/Showing a Form Control with another Form Control
    By SonOfOdin in forum Excel General
    Replies: 2
    Last Post: 06-20-2012, 09:55 AM
  5. Active x, excel sheet form control
    By erikgutten in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 08-19-2010, 09:19 AM

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