+ Reply to Thread
Results 1 to 2 of 2

Copy an image into a cell

  1. #1
    Registered User
    Join Date
    12-10-2012
    Location
    Oxford
    MS-Off Ver
    Excel 2000
    Posts
    10

    Copy an image into a cell

    How do I set a copied image as a cells value.

    An ex-colleague has inserted map images saved on a one worksheet into other worksheets depending on the images code. I wish to do the same but not sure how.

    Any help would be gratefully received as I have a deadline in an hour.

    Thanks

  2. #2
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,048

    Re: Copy an image into a cell

    THese are some instructions I was given a while back to insert a pic, based on a drop-down...
    Assumption: Pictures are stored on Sheet2 and will be dynamically shown on Sheet1.

    Select Sheet2 and turn off Grid Lines
    • View...Uncheck: Grid Lines

    1) For each picture to be displayed:
    1a. Insert.Picture...(select picture and put it in the sheet).
    1b. Select the range of cells that is under the picture.
    1c. Name that range of cells, using the prefix "pic" followed by the dropdown list text:
    Example for a picture of an Elephant:
    Formulas.Name_Manager.New
    ...Name: picElephant
    ...Refers to: (this is whatever range you've selected under the elephant pic)

    2) Build your data validation list on a cell in Sheet1 and pick one of the items.

    3) Create a dynamic range name that refers to that cell:
    • Formulas.Name_Manager.New
    ...Name: ShowMyPic
    ...RefersTo: =INDIRECT("pic"&Sheet1!$A$1)
    or whatever cell you chose tha contains the dropdown list.

    4) Copy the range of cells under one of the pictures from Sheet2
    5) Select the display cell on Sheet1.
    6) Home.Paste.Paste.As_Picture.Picture_Link
    7) With the picture selected, type this in the formula bar, then press [Enter]:
    =ShowMyPic

    The picture will be replaced by the picture referred to by the dropdown list.

    Each time you select a different item in the list, the associated picture will appear in the picture box and resize appropriately
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

+ 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. Copy picture from ActiveX Image Command to a cell
    By jdvdh in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 08-25-2014, 03:38 PM
  2. Replies: 0
    Last Post: 07-08-2014, 06:27 AM
  3. VBA Copy image into cell.
    By Jago147 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-07-2014, 05:55 PM
  4. [SOLVED] Code to copy data in cell, but not image over cell.
    By Nitefox in forum For Other Platforms(Mac, Google Docs, Mobile OS etc)
    Replies: 7
    Last Post: 10-02-2013, 12:52 AM
  5. excel 2010 VBA InsertPicInRange only makes shortcut to image instead of copy of image
    By ArjanSpit in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 09-10-2012, 02:57 PM
  6. Formula to copy image to another cell
    By hotwoz in forum Excel General
    Replies: 0
    Last Post: 09-30-2010, 05:21 AM
  7. How to embed an image withon a cell as opossed to copy and paste
    By Karla Rodriguez in forum Excel Charting & Pivots
    Replies: 3
    Last Post: 11-04-2005, 11:10 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