TIdHTTP * http; void __fastcall IdHTTPConnected(TObject *Sender) { //bla-bla-bla } http->OnConnected = IdHTTPConnected;