EnableOLEDragMethod (ImageList Control) example for C++ Builder
void __fastcall TForm1::btnStartDragClick(TObject *Sender)
{
LEADImgList1->LoadFromFile("c:\\Image1.tif", 0, 0, -1);
LEADImgList1->AllowSelection = ALLOWSELECTION_SINGLE;
LEADImgList1->EnableOLEDragMethod = true;
LEADImgList2->EnableOLEDragMethod = true;
LEADImgList1->OLEDragCursor = (L_HCURSOR)(this->Icon->Handle);
}
void __fastcall TForm1::btnStopDragClick(TObject *Sender)
{
LEADImgList1->EnableOLEDragMethod = false;
LEADImgList2->EnableOLEDragMethod = false;
}
void __fastcall TForm1::LEADImgList1OLEGiveFeedback(bool &bUseDefaultCursor)
{
bUseDefaultCursor= false;
}