General information
Category:
Coding, syntax & commands
Tom, normally you use the command
your_grid.recordsource=your_grid.recordsource
and then maybe
your_grid.setfocus
to reset the grid to the new cursor or table - this will work as long as the field types are the same in the new table as they were before
>Hi, Tom...
>
>Yes, it is possible first to establish recordsource of the grid
>to {NONE} and then after sql command columns of the grid will
>not blow away. But this is true in just one case:
>when the grid's columns have the same order as in the
>cursor. I mean the following:
>Cursor's fields: f1, f2, ...
>Grid columns controlsources: f1, f2, ...
>Hovewer, if you don't want to show field f2 and bound
>second column's controlsource to f3, then after re sql command
>you should redefine this column because it bounds to f2.
>It can happen to other columns (and they also need to be
>redifined).
>Or, you can create cursor in such a way that all columns you
>don't want to show are located in the tail of the cursor and
>then you can just one time define columncount of the grid.
>
>All the best.
Previous
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only