FreeDialogs example for C++ Builder
void __fastcall TForm1::FormClose(TObject *Sender, TCloseAction &Action) { LEADDlgService1->FreeDialogs ( ); }