Re: Is this correct? (TADOConnection)



Not sure what you are asking, the code is from the unit ADODB. Are you
wondering if your connection/object is free at this point?
Frederico Pissarra wrote:
Hello!!!

Taking a look at ADODB unit in $(DELPHI)\Source\VCL (I'm using D7 here), you
can see the following code:

-------------%<------------cut here -------------%<------------------------
destructor TADOConnection.Destroy;
begin
Destroying;
Close;
ClearRefs;
FreeAndNil(FCommands);
if FConnEventsID > 0 then
OleCheck(ConnectionPoint.UnAdvise(FConnEventsID));
FConnEventsID := 0;
FConnectionObject := nil;
inherited Destroy;
end;

-------------%<------------cut here -------------%<------------------------

Notice that FConnectionObject is not released (calling IUnknown.Release),
but the reference simply will point to nil.

Is this correct?

[]s
Fred

.