views:

118

answers:

2

I have an application with a CRichEditView, and I'd like to find text in it. By creating a menu item "Find" with ID_EDIT_FIND, the view opens the find window and text is found by highlighting. BUT... the view is not scrolled, so if a text is found 100 lines below visible, that's where it stays. Ideas on how to make the control autoscroll so that found items are always visible ?

TIA /Rob

+3  A: 

Ok, answer:

ctrl.SetOptions(ECOOP_OR, ECO_AUTOVSCROLL);

That did the trick :)

Robert
+1 Well done for providing your own answer and placing it here.
ChrisBD
A: 

Another thing that's needed is:

ctrl.SetOptions(ECOOP_OR, ECO_NOHIDESEL);

So that selection shall always be visible.

Robert