Subject Re: [IBO] Showing NULL-Columns as in TIB_Grid
Author Jason Wharton
I don't follow what BUM is here.
I think you should just use BofRowNum. I believe the grid will validate and
make sure all pertinent records are in the buffer before the paint routines
are called. As such, it may not be important to consider the BufferHasBof
property.

Jason Wharton
CPS - Mesa AZ
http://www.ibobjects.com


----- Original Message -----
From: <lester@...>
To: <IBObjects@yahoogroups.com>
Sent: Thursday, November 22, 2001 1:17 AM
Subject: Re: [IBO] Showing NULL-Columns as <null> in TIB_Grid


> > > if (abs(DataSource.Dataset.BufferRowNum) >= 0) then begin
> > > if GridFields[ACol - 1].IsNull then AString := '<null>';
> > > end;
>
> > Rather than use 0 (which is an assumption) it should be replaced by the
> > BofRowNum property of the dataset. In most cases it will be 0 but there
are
> > those times it is less than or more than zero. It is also important to
take
> > the BufferHasBof property into consideration as well.
>
> So would this be better?
>
> if BufferHasBof then BUM := BofRowNum else BUM := 0;
> if BufferRowNum >= BUM then begin .....
>
> ( Scuse any incorect Delphi me speek Builder )
>
> --
> Lester Caine
> -----------------------------
> L.S.Caine Electronic Services
>