Solved

Detecting when new item is selected in list box.

Posted on 1998-09-07
2
157 Views
Last Modified: 2013-11-20
Hi eevryone,

How do you detect when a new item within a list box is selected (with the left-mouse-button)?  I know about LBN_SELCHANGE, but that is called before the new selection takes effect.  I want to know what the NEW selection is.

Example:
I select list item B in a list box.  I want to know what message (if any) is sent to tell me that list item B has been selected.  If no messages are sent that tell me this, then how do I accomplish this basic task?

Thanks.
0
Comment
Question by:ameteur
[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
2 Comments
 
LVL 2

Accepted Solution

by:
prasanth earned 50 total points
ID: 1321810
LBN_SELCHANGE is the currect message to be processing. When you process it, Use CListBox::GetCurSel or send LB_GETCURSEL to get the current selection.
0
 

Author Comment

by:ameteur
ID: 1321811
Thanks, it turned out I was doing something else wrong.
0

Featured Post

[Webinar] Code, Load, and Grow

Managing multiple websites, servers, applications, and security on a daily basis? Join us for a webinar on May 25th to learn how to simplify administration and management of virtual hosts for IT admins, create a secure environment, and deploy code more effectively and frequently.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Need a Shell script to start a service checking the port 6 56
string initialization in java 11 122
bigDiff challenge 17 142
Problem to App 4 145
Introduction: Dynamic window placements and drawing on a form, simple usage of windows registry as a storage place for information. Continuing from the first article about sudoku.  There we have designed the application and put a lot of user int…
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 …
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.
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…

734 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