+ Reply to Thread
Results 1 to 7 of 7

Click on shape to return message box of shape name

  1. #1
    Registered User
    Join Date
    10-20-2011
    Location
    london
    MS-Off Ver
    Excel 2007
    Posts
    98

    Click on shape to return message box of shape name

    Scoured the internet for an hour and still canot find a solution to something probably quite simple

    im using 2010

    When i click on a shape i want a message box to return the shape name.

    There are over 100 shapes and i dont want to have to create a seperate macro for each.

    Thanks for any help

    Beat
    Last edited by beat; 11-11-2013 at 12:24 PM.

  2. #2
    Forum Contributor
    Join Date
    03-21-2013
    Location
    Corvallis, OR
    MS-Off Ver
    Excel 2010
    Posts
    174

    Re: Click on shape to return message box of shape name

    Try this:
    Please Login or Register  to view this content.
    You would need to assign this macro to the object in order for it to run when you click the object.
    If I helped, please click on Add Reputation.

  3. #3
    Forum Expert MickG's Avatar
    Join Date
    11-23-2007
    Location
    Banbury,Oxfordshire
    Posts
    2,650

    Re: Click on shape to return message box of shape name

    Try, Like:=
    Please Login or Register  to view this content.

  4. #4
    Forum Contributor
    Join Date
    03-28-2013
    Location
    *
    MS-Off Ver
    Excel 2010
    Posts
    226

    Re: Click on shape to return message box of shape name

    Right Click on Shape
    Click on Assign Marco
    and in the middle of sub and end sub
    type the Shapename as below

    Please Login or Register  to view this content.
    Give Feedback and Click(*)

  5. #5
    Forum Contributor
    Join Date
    03-21-2013
    Location
    Corvallis, OR
    MS-Off Ver
    Excel 2010
    Posts
    174

    Re: Click on shape to return message box of shape name

    Even better MickG, yours is object specific. Excellent, thanks!

  6. #6
    Registered User
    Join Date
    10-20-2011
    Location
    london
    MS-Off Ver
    Excel 2007
    Posts
    98

    Re: Click on shape to return message box of shape name

    Still cant get this to work.

    The shapes have Hyperlinks as i wanted tool tips.


    To recap i want to left click on a shape and have it return the shape name

    Where do i put the code?

    Beat

  7. #7
    Forum Expert MickG's Avatar
    Join Date
    11-23-2007
    Location
    Banbury,Oxfordshire
    Posts
    2,650

    Re: Click on shape to return message box of shape name

    This does no appear to work with "Hyperlinks", could you not add the tooltip text to the msgbox in the code.
    Nb:- You need to right click the shape and select "Assign Macro",
    When the code widow appears you need to Place the following within the module
    Please Login or Register  to view this content.
    Last edited by MickG; 11-11-2013 at 01:10 PM.

+ 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. Automatically bringing a Shape into a Cell Using Shape Code
    By dineshtendulkar in forum Excel Programming / VBA / Macros
    Replies: 14
    Last Post: 12-16-2016, 02:25 PM
  2. [SOLVED] Use a button to control a macro that inserts an image into a shape or resets the shape
    By nwb in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 05-13-2013, 04:41 PM
  3. Add command button to shape and change shape color on mouseover
    By maacmaac in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 12-26-2012, 05:12 PM
  4. Replies: 0
    Last Post: 11-30-2012, 01:29 PM
  5. How Do I change the Shape of the Comment Box to Folded Corner Shape?
    By e4excel in forum Excel Programming / VBA / Macros
    Replies: 15
    Last Post: 09-01-2011, 08:17 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