+ Reply to Thread
Results 1 to 3 of 3

Load transparent pictures into Image Control using VBA

  1. #1
    Registered User
    Join Date
    12-06-2018
    Location
    Aarhus, Denmark
    MS-Off Ver
    2013
    Posts
    2

    Load transparent pictures into Image Control using VBA

    Hi Excel Forum

    I'm trying to use VBA to upload a partially transparent image into Image Control.

    The tricky part is that it has to keep it's transparency, so that I could stack several images on top of each other. I've read that .png files are not supported - any ideas for a solution?

  2. #2
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258

    Re: Load transparent pictures into Image Control using VBA

    Hello R.lauritsen,

    Welcome to the forum!

    What code are you using to upload the images?

    When you say "transparency" do you mean full or partial?

    Please explain what you mean PNG files are not supported?
    Sincerely,
    Leith Ross

    Remember To Do the Following....

    1. Use code tags. Place [CODE] before the first line of code and [/CODE] after the last line of code.
    2. Thank those who have helped you by clicking the Star below the post.
    3. Please mark your post [SOLVED] if it has been answered satisfactorily.


    Old Scottish Proverb...
    Luathaid gu deanamh maille! (Rushing causes delays!)

  3. #3
    Registered User
    Join Date
    12-06-2018
    Location
    Aarhus, Denmark
    MS-Off Ver
    2013
    Posts
    2

    Re: Load transparent pictures into Image Control using VBA

    Hi Leith!

    So far my attempts have been with this simple line of code:
    Please Login or Register  to view this content.
    This works for the JPEG image I have tested this with, but this uploads the picture along with the background.

    I'm trying to upload the picture without the background, but that doesn't seem possible with a JPEG file, and when I try with a PNG file i get Runtime Error '481': Invalid Picture. That is why I believe PNG files are not supported by Image Control.

+ 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. Load picture using image control
    By hjoemark27 in forum Excel Charting & Pivots
    Replies: 2
    Last Post: 04-18-2018, 09:07 AM
  2. Load picture using image control
    By hjoemark27 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-18-2018, 07:30 AM
  3. Replies: 0
    Last Post: 10-31-2016, 06:37 PM
  4. How do i load pictures into the image frame in the worksheet?
    By josaah in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-23-2016, 01:03 PM
  5. [SOLVED] Change the background of an image to transparent
    By worthm in forum Excel General
    Replies: 3
    Last Post: 01-07-2015, 02:20 PM
  6. How to load a picture from worksheet to image control?
    By ZahraShuaib in forum Excel General
    Replies: 3
    Last Post: 07-28-2010, 03:16 AM
  7. Transparent background image?
    By metalsped in forum Excel General
    Replies: 0
    Last Post: 04-30-2005, 09:16 AM

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