An application sends a CB_SETCURSEL message to select a string in the list of a combo box. If necessary, the list scrolls the string into view. The text in the edit control of the combo box changes to reflect the new selection, and any previous selection in the list is removed.
CB_SETCURSEL wParam = (WPARAM) index; // item index lParam = 0; // not used; must be zero
If the message is successful, the return value is the index of the item selected. If index is greater than the number of items in the list or if index is set to -1, the return value is CB_ERR and the selection is cleared.
CB_FINDSTRING, CB_GETCURSEL, CB_SELECTSTRING
file: /Techref/os/win/api/win32/mess/src/msg02_4.htm, 1KB, , updated: 2000/4/7 12:19, local time: 2024/8/25 11:08,
18.191.45.195:LOG IN
|
©2024 These pages are served without commercial sponsorship. (No popup ads, etc...).Bandwidth abuse increases hosting cost forcing sponsorship or shutdown. This server aggressively defends against automated copying for any reason including offline viewing, duplication, etc... Please respect this requirement and DO NOT RIP THIS SITE. Questions? <A HREF="http://piclist.com/Techref/os/win/api/win32/mess/src/msg02_4.htm"> CB_SETCURSEL</A> |
Did you find what you needed? |
![]() o List host: MIT, Site host massmind.org, Top posters @none found - Page Editors: James Newton, David Cary, and YOU! * Roman Black of Black Robotics donates from sales of Linistep stepper controller kits. * Ashley Roll of Digital Nemesis donates from sales of RCL-1 RS232 to TTL converters. * Monthly Subscribers: Gregg Rew. on-going support is MOST appreciated! * Contributors: Richard Seriani, Sr. |
Welcome to piclist.com! |
.