How do you do this??

DynamicArray : array of IMyInterface;

>From my understanding if you do SetLength(DynamicArray, 20) then the array
is uninitialised which is real bad when dealing with interfaces.

eg
  for I := 0 to High( DynamicArray) DynamicArray[ I ] := nil;
I expect to AV, as Delphi will attempt to call _Release before it assigns
nil to the array element and as the array element is full of junk it will
crash??

Suggestions anybody?
Myles Penlington.


---------------------------------------------------------------------------
    New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
                  Website: http://www.delphi.org.nz

Reply via email to