Subject Re: [IBO] Delphi doesn't see new fields at runtime?
Author Daniel Rail
Hi,

At August 15, 2006, 3:35 AM, ra8009 wrote:

> I modifed a field in a Firebird data table and added two new ones.
> Whether I use a TIBOTable or TIBOQuery, Delphi sees the new fields at
> design time becuase I can add them as persistent fields. Bizarrely,
> when I reference the new fields at runtime Delphi says they don't exist!

> I've tried referencing the field objects and also used fieldByName and
> FindField. I've also tried changing the field names to test1 and
> test2, rebooted, etc. etc. but nothing works.

> At runtime I even tried GetFieldNames, but the fields are not on the
> list. What could possibly be wrong?

If with the TIBOTable and TIBOQuery you are already using persistent
fields, then you wouldn't be able to see the new fields that would be
added in runtime. It's just how persistent fields work, if the field
is not added to the persistent fields in design-time, then you can't
access the field in runtime, even if it's part of the table or the
query's result set. If you want to be able to add fields to the
result set in run-time, then don't use persistent fields in
design-time.

--
Best regards,
Daniel Rail
Senior Software Developer
ACCRA Solutions Inc. (www.accra.ca)
ACCRA Med Software Inc. (www.filopto.com)