How can I make sure that every time I tab onto the grid (from another
control) the top left cell gets selected?
i.e. myGrid.column[1].row[1].setfocus
just thought, is this the usual way to work with grids?
any help much appreciated
thanks,
Pat
> How can I make sure that every time I tab onto the grid (from another
> control) the top left cell gets selected?
"How to focus a specific cell in a DBGrid"
http://delphi.about.com/od/adptips2005/qt/dbgridfocuscell.htm
~Zarko Gajic
do the next:
myGrid.DataSource.Dataset.First; {to move to first record}
myGrid.SelectedIndex := 0; {to select first column}
--
With best regards, Mike Shkolnik
E-mail: mshk...@scalabium.com
WEB: http://www.scalabium.com
"Pat" <p...@downunder.com> wrote in message
news:437o62d3635g6pm9l...@4ax.com...
>do the next:
>myGrid.DataSource.Dataset.First; {to move to first record}
>myGrid.SelectedIndex := 0; {to select first column}
I still cannot get to the first row, first column; it takes me to the
2nd column.
The only way I can get to the 1st column is make the 1st and 2nd
column the identical field and then make the 1st column visible
property = FALSE.
at least the user will think he's at the first column
I cannot get it to compile with the OVERLOAD directive present.
I get compile error:
myForm.pas(2202): Invalid compiler directive: 'OVERLOAD'
Am using Delphi v6, do I have to add something else somewhere?
thanks