Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Subclassing scrollbars in list and tree controls

Posted on 2002-05-09
5
Medium Priority
?
442 Views
Last Modified: 2010-05-18
How can I subclass the scrollbar inside a CListCtrl or a CTreeCtrl.  The method GetScrollBarCtrl returns NULL. My lists and tree are very nice but I'm stuck with ugly gray scrollbars. I only I could get a hold on it...
0
Comment
Question by:mahtieubrault
[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
  • 4
5 Comments
 
LVL 2

Expert Comment

by:antoinebf
ID: 6999807
From my limited experience (it's also been a while...), you have to implement your own... and draw them on top of those grey ones... It's a nice hack, but then again, what isn't in windows...

"That custom scroll bar would then relay the scroll messages directly to treectrl. We also had to implement all the displays of the scrollbar (thumb, buttons, etc.)"
  - cyberbum

I'll try to find my old stuff and mail some useful info from it to you...

A.
0
 

Author Comment

by:mahtieubrault
ID: 6999814
Thanks Tony,

Do I have to paint after the WN_NCPAINT ?
0
 
LVL 2

Expert Comment

by:antoinebf
ID: 6999820
From my limited experience (it's also been a while...), you have to implement your own... and draw them on top of those grey ones... It's a nice hack, but then again, what isn't in windows...

"That custom scroll bar would then relay the scroll messages directly to treectrl. We also had to implement all the displays of the scrollbar (thumb, buttons, etc.)"
  - cyberbum

I'll try to find my old stuff and mail some useful info from it to you...

A.
0
 
LVL 2

Expert Comment

by:antoinebf
ID: 6999830
From my limited experience (it's also been a while...), you have to implement your own... and draw them on top of those grey ones... It's a nice hack, but then again, what isn't in windows...

"That custom scroll bar would then relay the scroll messages directly to treectrl. We also had to implement all the displays of the scrollbar (thumb, buttons, etc.)"
  - cyberbum

I'll try to find my old stuff and mail some useful info from it to you...

A.
0
 
LVL 2

Accepted Solution

by:
antoinebf earned 600 total points
ID: 6999869
sorry for duplicate comments... it got out of control I don't know how!!! :(

0

Featured Post

What’s Wrong with Your Cloud Strategy ?

Even as many CIOs are embracing a cloud-first strategy, the reality is that moving to the cloud is a lengthy process and the end-state is likely to be a blend of multiple clouds—public and private. Learn why multicloud solutions matter in this webinar by Nimble Storage.

Question has a verified solution.

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

C++ Properties One feature missing from standard C++ that you will find in many other Object Oriented Programming languages is something called a Property (http://www.experts-exchange.com/Programming/Languages/CPP/A_3912-Object-Properties-in-C.ht…
Article by: evilrix
Looking for a way to avoid searching through large data sets for data that doesn't exist? A Bloom Filter might be what you need. This data structure is a probabilistic filter that allows you to avoid unnecessary searches when you know the data defin…
The viewer will learn how to user default arguments when defining functions. This method of defining functions will be contrasted with the non-default-argument of defining functions.
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.
Suggested Courses

636 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