Solved

CScrollBar object in a CView

Posted on 1998-01-19
1
248 Views
Last Modified: 2011-10-03
With VC++ 4.0, is it possible and how to proceed to create a CScrollBar Object in a CView (not the CWnd::ShowScrollBar() function)?  I'd like to have my view with some frames like a web page to display informations entered by the user.

Thanks
0
Comment
Question by:adnrwin
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 23

Accepted Solution

by:
chensu earned 50 total points
ID: 1178523
Several methods:
1. Use CScrollView instead of CView.
2. In OnCreate(), call ModifyStyle to apply WS_HSCROLL or WS_VSCROLL.
3. Add a member variable CScrollBar m_sbar, and create it (m_sbar.Create) in OnCreate of your CView.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Unlike C#, C++ doesn't have native support for sealing classes (so they cannot be sub-classed). At the cost of a virtual base class pointer it is possible to implement a pseudo sealing mechanism The trick is to virtually inherit from a base class…
Templates For Beginners Or How To Encourage The Compiler To Work For You Introduction This tutorial is targeted at the reader who is, perhaps, familiar with the basics of C++ but would prefer a little slower introduction to the more ad…
The goal of the tutorial is to teach the user how to use functions in C++. The video will cover how to define functions, how to call functions and how to create functions prototypes. Microsoft Visual C++ 2010 Express will be used as a text editor an…
The viewer will learn how to use the return statement in functions in C++. The video will also teach the user how to pass data to a function and have the function return data back for further processing.

733 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question