images in tab controls

I have added an image to a tab ctrl through an image map.  The image looks goofy though because it picks up the background color of the window, instead of just staying the color of the tab control.  Any suggestions?
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Set image background color exactly color of window...


Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Nicolay is correct, you should set the image list bk color to be the system bk color.
This is the code which does this:

pfauxAuthor Commented:
this doesn't appear to work right...there is no change to the images background color, even when I change COLOR_WINDOW to COLOR_ACTIVEBORDER, etc.

I even tried setting this when we are adding the image list
m_smlImageList.Add( &m_SmallMap,
   GetSysColor(COLOR_WINDOW) );

and that just causes the background to be a pink color

any suggestions?
pfauxAuthor Commented:
figured it out, here is what I finally did, in the spot where I am inserting the image.

ptr.iImage = 64;

pfauxAuthor Commented:
i'll accept your answer because you are kind of correct.  I did need to set the background but needed to set it to that it would be transparent.  Only found that because the other way did not work.  You did get me into the correct area in the documentation to find the right answer.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
System Programming

From novice to tech pro — start learning today.