Thread: Rich Edit Control - Get And Set Caret Position?

  1. #1
    Registered User
    Join Date
    Dec 2005
    Posts
    2

    Rich Edit Control - Get And Set Caret Position?

    I can't find out how to get and set the caret position for a rich edit control. Is there any way to do this?

    Thanks a lot for your help.

  2. #2
    Registered User
    Join Date
    Dec 2005
    Posts
    2
    I was trying a few things this morning and I found that setting the min and max of a CHARRANGE to the desired caret position and sending a EM_EXSETSEL message works for setting the caret position. For getting the caret position EM_EXGETSEL works.

    I can't find any other way to do it so I assume that's the correct method.

Popular pages Recent additions subscribe to a feed