title: Fetching CBitmap out of CImageList
body: <p>I inserted bitmaps in CImageList in one Function and needed to change some of the images later in another function.  But I am unable to extract the CBitmap. The code goes something like this:</p>
  
  <pre><code>CBitmap GetIndividualBitmap(CImageList oImgList, int nBmpNo)
  {   
      IMAGEINFO imgInfo;
      imagelist.GetImageInfo(index,imgInfo);
      CBitmap bmp;
      bmp.FromHandle(imgInfo.hbmImage);
      return bmp;
  }
  </code></pre>
  
  <p>However all I get is a black screen.  Could anyone please point out where I am going wrong?</p>