+ Reply to Thread
Results 1 to 3 of 3

Simple VBA for cell shape to display image DRIVING ME MAD

  1. #1
    Forum Contributor
    Join Date
    04-09-2014
    Location
    England
    MS-Off Ver
    Excel 2010
    Posts
    250

    Question Simple VBA for cell shape to display image DRIVING ME MAD

    Hi,

    I have this code for a cell to display a particular image when it is clicked - works fine.
    my issue is, I then want the image to disappear the next time I click it. like an on-off button. but I cant figure out how to do that.
    at the moment once the image is there, it will not go away unless I remove it manually.

    this is the code im using:


    Please Login or Register  to view this content.

    I tried changing it to an if statement with an else . but nothing works.

    any ideas?

  2. #2
    Forum Guru romperstomper's Avatar
    Join Date
    11-04-2008
    Location
    A1
    MS-Off Ver
    Most
    Posts
    12,302

    Re: Simple VBA for cell shape to display image DRIVING ME MAD

    You should be able to use something like this:
    Please Login or Register  to view this content.
    depending on what formatting you want when there is no picture.
    Remember what the dormouse said
    Feed your head

  3. #3
    Forum Contributor
    Join Date
    04-09-2014
    Location
    England
    MS-Off Ver
    Excel 2010
    Posts
    250

    Re: Simple VBA for cell shape to display image DRIVING ME MAD

    theres my man rory. always on cue, if not a bit late to the office today ha

    thanks mate that's beautiful. now I can use that to add to the loooong code I have for one button . making it click and change picture to a tick and send automatic email out etc then NOT send email when clicked when picture present and change to plain white again.

    cheers mate

+ 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. Image, shape cell selection
    By Tootill in forum Excel General
    Replies: 3
    Last Post: 01-07-2015, 10:17 AM
  2. [SOLVED] Linking Image to a cell value, and display the selected image in new sheet
    By siva venkata in forum Excel General
    Replies: 12
    Last Post: 03-25-2014, 02:34 AM
  3. [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
  4. Display Image Based On Image Name In Cell
    By processchip in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-01-2011, 10:11 AM
  5. Driving an image control with a listbox
    By luke in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 04-22-2005, 05:56 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