Solved

CListView - Item selection

Posted on 1998-09-30
1
254 Views
Last Modified: 2013-11-20
hi,
I have two list views ( derived from CListView ) in a
Splitter Wnd. I need the folowing behaviour:
If I select an item in one of the views a secound item
in the other view should be selected ( or marked!? ...blue
background ...). If I remove the focus from the view the
items in the view are not longer selected!It seems to me,
that items can only be selected if the view including them,
has the focus!? So only one view can have selected (marked)
items!
Am I right?
dib
0
Comment
Question by:dib
1 Comment
 
LVL 8

Accepted Solution

by:
Answers2000 earned 150 total points
Comment Utility
>> Am I right ?
No

Add LVS_SHOWSELALWAYS4 style to the listview and it will always show its selection even when it doesn't have the focus.  You can add this style when creating the window or by overriding PreCreateWindow and using
cs.style |= LVS_SHOWSELALWAYS ;

0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

Introduction: Dialogs (1) modal - maintaining the database. Continuing from the ninth article about sudoku.   You might have heard of modal and modeless dialogs.  Here with this Sudoku application will we use one of each type: a modal dialog …
Have you tried to learn about Unicode, UTF-8, and multibyte text encoding and all the articles are just too "academic" or too technical? This article aims to make the whole topic easy for just about anyone to understand.
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…

762 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

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now