Found the problem. I defined the hack class as a decendant of TStringList and it should have been TStrings. It's working now.

Cheers,
Ross.

----- Original Message ----- From: "Ross Levis" <[EMAIL PROTECTED]>
To: "NZ Borland Developers Group - Delphi List" <[EMAIL PROTECTED]>
Sent: Friday, September 17, 2004 4:28 PM
Subject: Re: [DUG] TStringList.FList



Hi Dennis

Thanks for the hack. It seems to be working in some respect but I can't access the data in the FList array for some reason. I'm getting either garbage or an access violation.

MasterDetails := TStringList.Create;
Index := MasterDetails.Add('ABC');
showmessage(THackStringList(MasterDetails).FList^[Index].FString);

THackStringList is defined as you specified.

I can't work out what is wrong with this.  Anyone?

Thanks,
Ross.

_______________________________________________ Delphi mailing list [EMAIL PROTECTED] http://ns3.123.co.nz/mailman/listinfo/delphi

Reply via email to