If you know the first value in a Set you could use a combination of ORD, and PRED
Count := ORD( PRED( FirstValue )) - ORD( FirstValue)+ 1;
You would probably have to use RTTI to get the first element.
Myles
-----Original Message-----
From: Jim Zheng [SMTP:[EMAIL PROTECTED]]
Sent: Friday, February 19, 1999 2:01 PM
To: Multiple recipients of list delphi
Subject: [DUG]: about SET
Hi all,
Does anyone know how to get the number of element in a set and how to know
the value stored in first, second .. position of a set easily?
I know we can loop through the whole set, but is there any faster way?
Thanks,
Jim Zheng
---------------------------------------------------------------------------
New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
Website: http://www.delphi.org.nz
application/ms-tnef