Scrollbar problem with RichTextBox

  • Thread starter Thread starter Joe Pilot
  • Start date Start date
J

Joe Pilot

Hi,

I don't know if this is a bug or is it just me not finding the
solution?

In VC# 2005 (running Windows2000) I have a multiline RichTextBox
with ScrollBars set to "Both", but not forced. So I want to see
no scrollbars at the beginning, and then, while filling up the
Box with text, they should appear with a proportional thumb as
usual. When deleting some text, the bars should disappear again.

Well, instead of that, I get the following: As long as I don't
resize the window, I can type in text without problems, but no
scrollbars appear when arriving at the bottom or at the right.
Only when I then resize the window (might be by only 2 mm), the
scrollbars appear as they should, and from then on, everything
works fine untill I close the app. But when I resize before
reaching the margins, then dysfunctional scrollbars appear, with
nonproportional thumbs, and the stay there until the text
reaches the margins, for then to turn to normal scrollbars for
the rest of the app's life. This behavior is independently for
the horizontal and vertical scrollbar, each of them waiting text
to come to its corresponding margin (right or bottom) before
starting to work as it should, provided a resize has been
done once.

Quite annoying, what am I doing wrong?


Thanks for any help

Joe
 
Okay, solution found: it was the ShowSelectionMargin property.
This has to be be set to False, for the scrollbars to work
properly. Well, this is bad news, because I wanted to have this
options but also the standard scrollbar behavior. Anybody with a
workaround?

Thanks

Joe
 
Back
Top