SftTree/DLL 7.5 - Tree Control
SftBox/OCX 5.0 - Combo Box Control
SftButton/OCX 3.0 - Button Control
SftMask/OCX 7.0 - Masked Edit Control
SftTabs/OCX 6.5 - Tab Control (VB6 only)
SftTree/OCX 7.5 - Tree Control
SftPrintPreview/DLL 2.0 - Print Preview Control (discontinued)
SftTree/DLL 7.5 - Tree Control
SftBox/OCX 5.0 - Combo Box Control
SftButton/OCX 3.0 - Button Control
SftDirectory 3.5 - File/Folder Control (discontinued)
SftMask/OCX 7.0 - Masked Edit Control
SftOptions 1.0 - Registry/INI Control (discontinued)
SftPrintPreview/OCX 1.0 - Print Preview Control (discontinued)
SftTabs/OCX 6.5 - Tab Control (VB6 only)
SftTree/OCX 7.5 - Tree Control
SftTabs/NET 6.0 - Tab Control (discontinued)
SftTree/NET 2.0 - Tree Control
Loads an image from a resource as a GDI+ image.
VB.NET | object.LoadImageFromResource(ByVal ResourceHandle As Integer, ByVal ResourceType As String, ByVal ResourceName As String) |
VB | object.LoadImageFromResource(ByVal ResourceHandle As LONG_PTR, ByVal ResourceType As String, ByVal ResourceName As String) |
C#.NET | void object.LoadImageFromResource(int ResourceHandle, string ResourceType, string ResourceName); |
VC++ | HRESULT object->LoadImageFromResource(LONG_PTR ResourceHandle, _bstr_t ResourceType, _bstr_t ResourceName); |
C | HRESULT object->raw_LoadImageFromResource(LONG_PTR ResourceHandle, BSTR ResourceType, BSTR ResourceName); |
object
A SftPictureObject object.
ResourceHandle
The handle to an instance of the module containing the resource.
ResourceType
The resource type. Can be a string or an identifier using the MAKEINTRESOURCE macro.
ResourceName
The resource name. Can be a string or an identifier using the MAKEINTRESOURCE macro.
The LoadImageFromResource method loads an image from a resource as a GDI+ image.
This function is identical to the GDI+ function Gdiplus::Bitmap::FromResource().
The image object is owned by the tree control and will be deleted when it is no longer used.
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]; C->Image->raw_LoadImageFromResource((long) AfxGetApp()->m_hInstance, L"PNG", (LPWSTR)MAKEINTRESOURCE(resourceID)); C->ImageHAlign = Align; PropagateImage(ItemIndex, C->Image); } void CPicturesDlg::UpdateIcon(long ItemIndex, HICON hIcon, SftTreeHAlignConstants Align) { ISftTreeCellPtr C = m_vTree->Cell[ItemIndex][0];
See Also SftPictureObject Object | Object Hierarchy