Image Viewer CP ActiveX Control

DrawImageHBITMAP

 

Draw the image from HBITMAP handle.

Public Function DrawImageHBITMAP( _
   ByVal iXPos As Integer, _
   ByVal iYPos As Integer, _
   ByVal hBitmapHandle As long, _
   ByVal clrTran As Color, _
   ByVal iAlphaValue As Integer
) 

 

Parameter

iXPos
   Specifies the logical x-coordinate of the starting point of the image.

iYPos
   Specifies the logical y-coordinate of the starting point of the image.

hBitmapHandle
   the HBITMAP handle.

clrTran
   the transparent color of overlay image.

iAlphaValue
   the alpha value of overlay image, range from 0-255. 255 = fully visble.


Return Value

No return value.


Example

   

Visual Basic Syntax
ImageViewer1.FileName="c:\test1.jpg"
ImageViewer1.ShowImage=True
ImageViewer1.DrawImageFromHBITMAP 0, 0, hbitmaphandle, RGB(0,0,0), 255