Subject Re: TIB_Query.fieldsvisible
Author Paolo Fenelli <paolopf@libero.it>
Hi George,
thanks i'll try.
But preparing the query shouldn't insert in the fieldsvisible string
list 'FieldName=' for all the fields in the query?
However i've already tried, with bad result, to make a clear / add
('FieldName=FALSE').

Cheers
Paolo.
--- In IBObjects@yahoogroups.com, "georgethenorge <ghelmke@o...>"
<ghelmke@o...> wrote:
> Lucky for you I just figured this out today myself ;)
>
> Here goes:
>
> You need to be sure that the param/value you are trying to change is
> actually present, otherwise the fieldsvisible[0] is going to put you
> out of bounds for the StringList.
>
> I prefer the following code:
> FieldsVisible.Values['FieldName'] := 'FALSE';
> I believe that this syntax will add the value to the StringList if
it
> isn't already there. If not, you will need to add it with an
> add('FieldName=FALSE')
>
> Good luck.
>
> George
>
>
>
> --- In IBObjects@yahoogroups.com, "Paolo Fenelli <paolopf@l...>"
> <paolopf@l...> wrote:
> > Hi list,
> > i need to change the visible property of fields in a TIB_Query at
> > runtime
> > i've tried:
> > with IB_Query do
> > prepare;
> > fieldsvisible[0] := 'FieldName=FALSE';
> > open;
> > end;
> > but it raises the exception:
> > List index out of bounds(1)
> >
> > Any help appreciated.
> >
> > Paolo Fenelli