is nich getestet, aber ich hab mich kurz mit der TClientSocket komponente auseinandergesetzt und das dürfte sein, wonach du suchst:
Delphi-Quellcode:
interface
uses ScktComp;
type TClientSocketDescendant = class(TClientSocket)
private
protected
procedure Event(Socket: TCustomWinSocket; SocketEvent: TSocketEvent); override;
public
published
end;
implementation
procedure TClientSocketDescendant.Event(Socket: TCustomWinSocket; SocketEvent: TSocketEvent);
begin
if SocketEvent = seConnect then
DoWhateverYouFeelLike(WithTheParamsYouWantOrNeed);
inherited;
end;
end;
hoffe es klappt