amrihuang Posted April 3, 2013 Share Posted April 3, 2013 Hi All, I want to set a grid's cell to focus, How can I coding? Thanks. Quote Link to comment Share on other sites More sharing options...
amrihuang Posted April 5, 2013 Author Share Posted April 5, 2013 +1 to top. Many thanks. Quote Link to comment Share on other sites More sharing options...
Administrators Farshad Mohajeri Posted April 5, 2013 Administrators Share Posted April 5, 2013 There are two protected properties: property CurrRow:Integer read FCurrRow write SetCurrRow; property CurrCol:Integer read FCurrCol write SetCurrCol; Quote Link to comment Share on other sites More sharing options...
amrihuang Posted April 5, 2013 Author Share Posted April 5, 2013 Many thanks Farshad. How can I coding it use delphi code? Current row is fix by dataset cursor, so whether uses like FocusedColumnIndex to make grid focus and cursor on the correct columnindex. Quote Link to comment Share on other sites More sharing options...
Administrators Farshad Mohajeri Posted April 5, 2013 Administrators Share Posted April 5, 2013 type TDBGridHack = class(TuniDBGrid); TDBGridHack(UniDBGrid1).CurrCol=3; Quote Link to comment Share on other sites More sharing options...
amrihuang Posted April 6, 2013 Author Share Posted April 6, 2013 I am test is ok. Thanks Farshad. I am a suggestion, whether can public the 2 properties to set, because when use grid to input data, this is so useful. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.