CTreeCtrl & scroll bars
Michael R Thompson -- mike@tracker.com.au
Tuesday, April 02, 1996
Environment: Win95, VC++ 4.0 & MFC
Does anybody know if there is a way to disable the scrollbars in a =
CTreeCtrl so that neither scroll bar is visible. I would also like to =
know if there is a way to make the horizontal permanently visible (by =
default it is only visible when there is an item in the list which is =
wider than the control).
Mike.
Gonzalo Isaza -- gonzaloi@microsoft.com
Wednesday, April 03, 1996
[Mini-digest: 2 responses]
I have not tried it, but my guess is calling ShowScrollBar(SB_BOTH,
FALSE) would do it. CTreeCtrl derives from CWnd so this member function
should work OK.
Gonzalo Isaza
[I speak for myself. I do not speak for Microsoft]
-----From: Ken Freeman
It looks like the control dynamically adds or removes WS_VSCROLL and
WS_HSCROLL styles as needed. So you probably can handle all events that
might cause the scroll bars to appear/disappear (resizing, adding/removing
items, renaming items, etc.) and force the styles to whatever you want.
I haven't actually tried this.
Ken
| Вернуться в корень Архива
|