toanphan
asked on
How to position the caret in CEdit
When I select the entire text in an edit box by calling CEdit::SetSel, the caret is automatically moved to the end of the selection. However, I want to be able to keep the caret at the beginning of the text when it's highlighted, not at the end of it. So the question is, is there a way to move the caret to position 0 in a CEdit when the text highlighted?
Toan Phan
Toan Phan
ASKER
The caret is a shared resource, and a call to SetCaretPos for CEdit does not have any effect. Any examples how to do this would really help.
Thanks.
Thanks.
ASKER
The caret is a shared resource, and a call to SetCaretPos for CEdit does not have any effect. Any examples how to do this would really help.
Thanks.
Thanks.
Use CEdit::SetSel(...)
Sorry, didnt read the question fully. The answer is not there isnt.
ASKER
Bridge did not give the answer as he misread the question. Any other answers?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
I hope this helps.
Dave.