-
January 24th, 2010, 05:43 PM
#1
RichEdit - NOT select text by default
We are using VC++ v6 and have a control on a form that is a RichEdit. When there is data in the control, and you tab into it, it of course selects and hilights all the text. Is there a way to NOT do that and put the cursor in the first position?
-
January 25th, 2010, 04:25 AM
#2
Re: RichEdit - NOT select text by default
Try:
Code:
Edit_SetSel(hRTF, 0, 0);
-
January 25th, 2010, 09:45 AM
#3
Re: RichEdit - NOT select text by default
The control is called... m_edit
I have....
m_edit.SetSel(0,0)
as the last line in the OnInitDialog.
That didn't work. When I tab into it, it still hilights it all.
Pete
-
January 25th, 2010, 10:04 AM
#4
Re: RichEdit - NOT select text by default
Sorry, I don't know MFC.
OnInitDialog is not the right place because it is not called when you tab into it. Maybe you have onFocus.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|