+ Reply to Thread
Results 1 to 3 of 3

Getting Image Name or Control Source

  1. #1
    Forum Contributor
    Join Date
    04-16-2020
    Location
    Alberta, Canada
    MS-Off Ver
    365
    Posts
    148

    Getting Image Name or Control Source

    I'm trying to get the name or control source (they are the same) of an image using the 'on click' event.

    if I use ActiveControl, it returns the textbox I was last in, not the image..

  2. #2
    Forum Expert dflak's Avatar
    Join Date
    11-24-2015
    Location
    North Carolina
    MS-Off Ver
    365
    Posts
    7,268

    Re: Getting Image Name or Control Source

    I think this might do it for you.

    Please Login or Register  to view this content.
    One spreadsheet to rule them all. One spreadsheet to find them. One spreadsheet to bring them all and at corporate, bind them.

    A picture is worth a thousand words, but a sample spreadsheet is more likely to be worked on.

  3. #3
    Forum Contributor
    Join Date
    04-16-2020
    Location
    Alberta, Canada
    MS-Off Ver
    365
    Posts
    148

    Re: Getting Image Name or Control Source

    It errors out at the "Dim ActiveShape As Shape".... "User-defined type not defined"

    if I comment that line out, "ButtonName = Application.caller" errros with "Method or data member not found"

    the selection type of what i'm clicking on is an image.

+ 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] Userform Image Control - Show specific region of Image
    By PrizeGotti in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 11-09-2021, 12:04 PM
  2. Insert and scale image using Image Control from Active X
    By olga6542 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-22-2020, 06:03 PM
  3. [SOLVED] VBA to transfer image FROM userform image control TO a worksheet cell
    By Zoediak in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-01-2014, 02:51 PM
  4. [SOLVED] Embed image to button using Image control
    By siobeh in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 02-12-2014, 05:37 PM
  5. [SOLVED] VBA to send embedded image in email body- NOT USING THE ORGINAL IMAGE SOURCE
    By Coreyusa in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 06-27-2013, 06:48 PM
  6. Displaying and Updating Image Dynamically (ActiveX Image Control?)
    By VTHokie11 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 11-02-2011, 10:57 AM
  7. [SOLVED] Programatically control picture property of Image control
    By Brassman in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 05-24-2005, 05:06 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