Problem using GetSelectedRows() after user keydown |
Post Reply |
Author | |
nguyena1
Groupie Joined: 28 November 2005 Status: Offline Points: 16 |
Post Options
Thanks(0)
Posted: 25 September 2006 at 12:08pm |
Hey all, has anyone had issues trying this?
I'm trying to have the user be able to hit the delete button on a selected row and have the item go away. The issue I'm having is using GetSelectedRows(). I'm handling the key down using NM_KEYDOWN and XTP_NM_REPORT_PREVIEWKEYDOWN. After I call GetSelectedRows(), GetCount or GetFirstSelectedRowPosition, I get 0 when I DO have a item selected. However, another case im handling is mouse clicks and selection changes using NM_CLICK and XTP_NM_REPORT_SELCHANGED. In the handling of message for these, GetCount or GetFirstSel... work fine. Is this because the keystrokes messages are sent before the reportcontrol sets up its CXTPReportSelectedRows? And I assume the other 2(click and selchanged) are messages sent after? I have also tried, GetFocusedRow, but this still returns a row even if I dont have a row selected. What is a solution that I can get the selected row after a user keydowns? Help would be much appreciated. Tony |
|
nguyena1
Groupie Joined: 28 November 2005 Status: Offline Points: 16 |
Post Options
Thanks(0)
|
FYI: I am using version 10.1
|
|
nguyena1
Groupie Joined: 28 November 2005 Status: Offline Points: 16 |
Post Options
Thanks(0)
|
Never mind! Sorry, I found out that somewhere else in a timered update, the selected rows were being cleared, which is why i wasn't seeing them on key down.
|
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |