Kurt
> You want the type of the object to be included in the type of the
> collection?
That is what the current TCollection does
>
> am I right to think you want this:
> TMySet = set of (TMyClass);
>
> MySet : TMySet;
> MyOtherClass : TMyOtherClass;
>
> ...
>
> MySet.Add( MyOtherClass); // Error Here!!
>
more
var
FItems: TSetof(TMyClass)
with FItems.Add do
try
// assign properties to an object of TMyClass
finally
end;
And it is not possible without Type Casting (which is what TList does)
with TMyClass(FItems.Add) do
try
// assign properties to an object of TMyClass
finally
end;
ttfn
---------------------------------------------------------------------------
New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
Website: http://www.delphi.org.nz
To UnSub, send email to: [EMAIL PROTECTED]
with body of "unsubscribe delphi"
- RE: [DUG]: Sorting a Collection Paul Heinz
- Re: [DUG]: Sorting a Collection Neven MacEwan
- RE: [DUG]: Sorting a Collection Nic Wise
- RE: [DUG]: Sorting a Collection Paul Heinz
- Re: [DUG]: Sorting a Collection Neven MacEwan
- RE: [DUG]: Sorting a Collection Paul Heinz
- Re: [DUG]: Sorting a Collection Neven MacEwan
- Re: [DUG]: Sorting a Collection Kurt
- Re: [DUG]: Sorting a Collection Neven MacEwan
- Re: [DUG]: Sorting a Collection Kurt
- Re: [DUG]: Sorting a Collection Neven MacEwan
- Re: [DUG]: Sorting a Collection Kurt
- Re: [DUG]: Sorting a Collection Neven MacEwan
- RE: [DUG]: Sorting a Collection Mike Mueller
- Re: [DUG]: Sorting a Collection Kurt
- Re: [DUG]: Sorting a Collection Neven MacEwan
- Re: [DUG]: Sorting a Collection Kurt
- Re: [DUG]: Sorting a Collection Neven MacEwan
- Re: [DUG]: Sorting a Collection Neven MacEwan
- RE: [DUG]: Sorting a Collection Nic Wise
- Re: [DUG]: Sorting a Collection Neven MacEwan
