/*
OnEndDrag example
This code displays a message on the status bar indicating whether a label was successfully dropped into and accepted by a another control.
*/ 
void __fastcall TForm1::StatusEndDrag(TObject *Sender, TObject *Target, int X, int Y)
{
  AnsiString S = ((TLabel *)Sender)->Name + " was dropped and ";
  if (Target)
    S = S + "accepted!";
  else
    S = S + "rejected.";
  StatusBar1->Panels->Items[0]->Text = S;
}  
