Rich Edit: select all
-
Can anyone tell me how to access/override/hook a rich edit control's select all (Ctrl + a). It throws up an error when trying to make any change to the selection or even select all a second time if there's more than one character for text. For some reason, if there's only one character, then it works just dandy. It says there's an assertion error in "array_d.cpp" and so I assume it's doing something that doesn't mesh with my method of serializing the data (into DWordArrays). So, if anyone knows exactly what it IS doing (like what messages it's sending where, and how to get at them), that'd be great. halblonious
-
Can anyone tell me how to access/override/hook a rich edit control's select all (Ctrl + a). It throws up an error when trying to make any change to the selection or even select all a second time if there's more than one character for text. For some reason, if there's only one character, then it works just dandy. It says there's an assertion error in "array_d.cpp" and so I assume it's doing something that doesn't mesh with my method of serializing the data (into DWordArrays). So, if anyone knows exactly what it IS doing (like what messages it's sending where, and how to get at them), that'd be great. halblonious
I have no idea about your problems but I wait for ON_WM_KEYDOWN() That's how I'm doing something on paste operation CTLT+V : void MyEdit::OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags) { if ( (nChar == 0x56) )//VK_V { if ( GetKeyState(VK_CONTROL) & 0xff00 ) {//do something} } } Mickey :)
-
I have no idea about your problems but I wait for ON_WM_KEYDOWN() That's how I'm doing something on paste operation CTLT+V : void MyEdit::OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags) { if ( (nChar == 0x56) )//VK_V { if ( GetKeyState(VK_CONTROL) & 0xff00 ) {//do something} } } Mickey :)
Wouldn't be handling
WM_PASTE
(WM_COPY
,WM_CUT
,WM_CLEAR
) better? :)
Who is 'General Failure'? And why is he reading my harddisk?!?
-
Wouldn't be handling
WM_PASTE
(WM_COPY
,WM_CUT
,WM_CLEAR
) better? :)
Who is 'General Failure'? And why is he reading my harddisk?!?
-
I have no idea about your problems but I wait for ON_WM_KEYDOWN() That's how I'm doing something on paste operation CTLT+V : void MyEdit::OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags) { if ( (nChar == 0x56) )//VK_V { if ( GetKeyState(VK_CONTROL) & 0xff00 ) {//do something} } } Mickey :)
Thanks for the reply, and I may have to resort to that, but I'm trying not to have to subclass the rich edit if I can help it. There must be some other way, I'm hoping. halblonious