Hide

SftTree/OCX 7.5 - ActiveX Tree Control

Display
Print

BitmapHandle Property, SftPictureObject Object

Defines the image object using a bitmap handle.

Syntax

Get

VB.NEThBitmap = object.BitmapHandle As Integer
VBhBitmap = object.BitmapHandle As OLE_HANDLE
C#.NETint hBitmap = object.BitmapHandle;
VC++OLE_HANDLE hBitmap = object->BitmapHandle;
OLE_HANDLE hBitmap = object->GetBitmapHandle();
CHRESULT object->get_BitmapHandle(OLE_HANDLE* hBitmap);

Put

VB.NETobject.BitmapHandle = hBitmap As Integer
VBobject.BitmapHandle = hBitmap As OLE_HANDLE
C#.NETint object.BitmapHandle = hBitmap;
VC++OLE_HANDLE object->BitmapHandle = hBitmap;
void object->PutBitmapHandle(OLE_HANDLE hBitmap);
CHRESULT object->put_BitmapHandle(OLE_HANDLE hBitmap);

object

A SftPictureObject object.

hBitmap

Defines the image object using a bitmap handle. The bitmap handle can be NULL, in which case the SftPictureObject object is cleared.

Comments

The BitmapHandle property defines the image object using a bitmap handle.

Typically, .NET applications use the NETImageObject property to define an image, C and C++ applications use BitmapHandle or Image, VB6 and other COM applications use the Picture property.

The SftPictureObject.Type property is set to sftTypeBitmap. The SftPictureObject.ActualHeight and SftPictureObject.ActualWidth properties reflect the image size.

Examples

C++

        m_vTree->Item[ItemIndex]->LabelImage = Img;
        m_vTree->Item[ItemIndex]->RowHeader->Image = Img;
    }
}

void CPicturesDlg::UpdateBitmap(long ItemIndex, const CBitmap& bmp, SftTreeHAlignConstants Align)
{
    ISftTreeCellPtr C = m_vTree->Cell[ItemIndex][0];
    C->Image->PutBitmapHandle((OLE_HANDLE)(HBITMAP) bmp);
    C->ImageHAlign = Align;
    PropagateImage(ItemIndex, C->Image);
}

void CPicturesDlg::UpdateImage(long ItemIndex, int resourceID, SftTreeHAlignConstants Align)
{
    ISftTreeCellPtr C = m_vTree->Cell[ItemIndex][0];

See Also SftPictureObject Object | Object Hierarchy


Last Updated 08/13/2020 - (email)
© 2022 Softel vdm, Inc.