+ Reply to Thread
Results 1 to 10 of 10

Vlookup a comment box with a picture in and view in userform

  1. #1
    Registered User
    Join Date
    08-08-2010
    Location
    London
    MS-Off Ver
    Excel 2003
    Posts
    4

    Vlookup a comment box with a picture in and view in userform

    Hi excel gurus,

    I have a macro which inserts pictures into comment boxes in a worksheets. I have also made a userform which uses vlookups to find data, What im trying to do with out much luck is to implement the picture in the comment boxes into the userform. For example when textbox1 is populated a vlookup is performed on the worksheet to find the cell with the comment box in. Then the comment box is displayed with the picture in on the userform possibly in an image. I hope someone can help as im at a complete lost now, thanks in advance
    Last edited by ebailey; 08-12-2010 at 05:51 AM.

  2. #2
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,124

    Re: Vlookup a comment box with a picture in and view in userform

    Here is an example of copying a comments image into a image control on a userform.

    It makes use of the PastePicture routines of Stephen Bullen.
    Attached Files Attached Files
    Cheers
    Andy
    www.andypope.info

  3. #3
    Registered User
    Join Date
    08-08-2010
    Location
    London
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Vlookup a comment box with a picture in and view in userform

    Thank you so much Andy, that is exactly what I was looking for, I can't thank you enough. Do you think it is possible to adapt the macro to search for a value in a text box by using a vlook up command or will it only work for one predetermined cell.

  4. #4
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,124

    Re: Vlookup a comment box with a picture in and view in userform

    Are you sure it's VLOOKUP in need to use. Hard to tell without seeing and example of your data layout but I would have thought MATCH or possible the Find method would be better suited.

    Can you post example file.

  5. #5
    Registered User
    Join Date
    08-08-2010
    Location
    London
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Vlookup a comment box with a picture in and view in userform

    Hi Andy, thanks again. I have made a quick example. What im after is when you type the number in the text box it will show the corrsponding picture in image1. Hope that make sense.
    Attached Files Attached Files

  6. #6
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,124

    Re: Vlookup a comment box with a picture in and view in userform

    Please Login or Register  to view this content.

  7. #7
    Registered User
    Join Date
    08-08-2010
    Location
    London
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Vlookup a comment box with a picture in and view in userform

    Andy thank you so much, i really do appreciate your help. Thanks

  8. #8
    Registered User
    Join Date
    01-28-2011
    Location
    Hundested, Denmark
    MS-Off Ver
    Excel 2007
    Posts
    1

    Re: Vlookup a comment box with a picture in and view in userform

    Hi Andy

    I'm looking for that very same functionallity, have read your advise, but must admit that it all exceeds my skill. So here goes: Where do I write the code? I have tried writing it in the "view code"-dialog box, but nothing happens. What sheet in the work book do I write the code in, or does writing it at the right place cover the whole workbook? Actually I'm looking for more precise directions. I have made a table with a collumn of titles and next to it a collumn of comments that I want to move to another sheet in the workbook, so that it looks like the sample file posted above - and I want to do it with vlookup. Can you help me?

    Regards Ulrik

  9. #9
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,124

    Re: Vlookup a comment box with a picture in and view in userform

    Your post does not comply with Rule 2 of our Forum RULES. Don't post a question in the thread of another member -- start your own thread. If you feel it's particularly relevant, provide a link to the other thread.

    Start a new thread. Post example workbook and explain exactly what it is about the answers in this tread that do not allow you to resolve your problem

  10. #10
    Registered User
    Join Date
    11-03-2008
    Location
    India
    MS-Off Ver
    Excel 2010
    Posts
    2,364

    Re: Vlookup a comment box with a picture in and view in userform

    Something very useful for Comments lookup which I was Googling now...

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

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