Subject | Re: [IBO] Grid cols does not alter FieldsIndex |
---|---|
Author | Markus Ostenried |
Post date | 2003-05-22T16:26:24Z |
At 16:47 Thursday, 22.05.2003 +0100, you wrote:
the property editor of a TIB_Query at design time.
Maybe this is what you're looking for (from the IBObjects help):
<quote>
Get the column of the grid from the column index of the dataset.
Applies toTIB_CustomGrid
Declaration: property GridCol[Index:integer]: integer;
</quote>
Have a look at the TIB_CustomGrid property GridFields, too.
E.g. IB_Grid1.GridFields[0].FieldName should return the name of the field
displayed in the first grid column.
This is especially useful in a grid's OnDrawCell event where you need to
know which field you have to draw.
HTH,
Markus
>If at runtime I alter the column positions the corresponding FieldsIndexI think moving a grid's coloumn does only alter the FieldsIndex when using
>of the attached query does not alter. How do I get the column positions?
the property editor of a TIB_Query at design time.
Maybe this is what you're looking for (from the IBObjects help):
<quote>
Get the column of the grid from the column index of the dataset.
Applies toTIB_CustomGrid
Declaration: property GridCol[Index:integer]: integer;
</quote>
Have a look at the TIB_CustomGrid property GridFields, too.
E.g. IB_Grid1.GridFields[0].FieldName should return the name of the field
displayed in the first grid column.
This is especially useful in a grid's OnDrawCell event where you need to
know which field you have to draw.
HTH,
Markus