Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Creating a CMainFrame Scrollbar

105 views
Skip to first unread message

Dan Rhein

unread,
Apr 30, 1997, 3:00:00 AM4/30/97
to

I am currently using MSVC 1.52c, My application is a MDI 16 bit
application.

I need to know how to create a Scrollbar for my CMainframe when my
CFormview objects are off the screen so that the user can scroll to the
area they need to view.

Any help would be appreciated!
Dan

hesiy...@gmail.com

unread,
Aug 8, 2014, 2:31:32 AM8/8/14
to
在 1997年4月30日星期三UTC+8下午3时00分00秒,Dan Rhein写道:
i had met such a issue before , this is my solution :
in MFC CMainFrame class find out the class member function
CMainFrame::PreCreateWindow(CREATESTRUCT& cs)

add following code lines :

cs.style|=WS_VSCROLL; // add the vertical scroll
cs.style|=WS_HSCROLL; // add the horizontal scroll

when your child windows engage the mainframe edge , the relative scroll bar would go work


Cholo Lennon

unread,
Aug 19, 2014, 12:47:40 PM8/19/14
to
OMG! A new record in this newsgroup... an answer after 17 years! (the OP
was using a 16 bit version of VC!)

Regards

--
Cholo Lennon
Bs.As.
ARG
0 new messages