CXTPPropertyGridInplaceEdit select all? |
Post Reply |
Author | |
cheez0r
Newbie Joined: 10 June 2009 Status: Offline Points: 1 |
Post Options
Thanks(0)
Posted: 10 June 2009 at 2:08pm |
Hello,
We have a propertygrid that creates inplace edit items when you click on one of the fields to edit the text. This works all great and fine, except that when the user clicks on one of cells, they'd like it to automatically select all the text in the field for ease of editting, rather than having to manually select it themselves. Sounds simple enough... But no matter where I"m putting the SetSel(0, -1), something later on is overridding that, and unhighlighting the text (I can even see it highlight the text if I put breakpoints right after my SetSel). I've been at it for a few days and can't figure out where in code it would undo this. Any help? |
|
znakeeye
Senior Member Joined: 26 July 2006 Status: Offline Points: 1672 |
Post Options
Thanks(0)
|
Not sure if this will help (I'm guessing now), but try changing the style of the edit control:
|
|
PokerMemento - http://www.pokermemento.com/
|
|
dennisV
Senior Member Joined: 07 October 2004 Location: Australia Status: Offline Points: 242 |
Post Options
Thanks(0)
|
I have the same issue - did you get it solved?
BTW, changing the style doesn't seem to work, at least like so: ((CXTPPropertyGridItem*)pItem)->SetEditStyle(WS_CHILD | ES_AUTOHSCROLL | ES_NOHIDESEL); |
|
// W7 64 Ultimate SP1
// VS 2008 // CodeJock 16.2.3 (MFC) |
|
dennisV
Senior Member Joined: 07 October 2004 Location: Australia Status: Offline Points: 242 |
Post Options
Thanks(0)
|
This has been solved through support (Mark Doubson). The way it can be done is like this:
BOOL CXTPPropertyGridItem::OnLButtonDown(UINT nFlags, CPoint point)Also, to enable selection when you click on the left side of the item (the item name) or when you use the keyboard to navigate: LRESULT CPropertyGridDlg::OnGridNotify(WPARAM wParam, LPARAM lParam) |
|
// W7 64 Ultimate SP1
// VS 2008 // CodeJock 16.2.3 (MFC) |
|
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 |