Problem with Tab-Key and a calculated field
Posted 09 April 2012 - 08:30 PM
my customer uses a DB Grid with the keyboard, i.e. switching between fields is done with the TAB key. I set WantTabs := true and it works well.
However, there is a problem. The grid contains one calculated column (the DB calculates a difference of two other fields). When one of the fields used for the calculation is changed, and my customer exits the row by pressing TAB, the active field does not move to the next row, but jumps to the second row. If another column is changed, it works as expected (active field enters the next row).
Do you understand my issue and could you provide help?
Posted 09 April 2012 - 10:57 PM
the problem is caused by the following refresh event handler:
procedure TdataForm.queryAfterPost(DataSet: TDataSet);
// Update auto-fields
So I could solve my problem by removing the call to Refresh. I still wonder how it would be possible to get an auto-updated field otherwise?
Posted 10 April 2012 - 03:34 AM
Can you please, if it doesn't consume much time for you to send me small demo project to I see it.
I am not sure how to reproduce it.
BergSoft Home Page: www.bergsoft.net
Members Section: bms.bergsoft.net
Articles and Tutorials: dn.bergsoft.net (Developers Network)
BergSoft Facebook page
Send us applications made with our components and we will submit them on: www.bergsoft.net/apps.htm. Link to this page will be also set on home page too.
Posted 13 April 2012 - 12:34 AM
I will contact you again if I have further problems!
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users