• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 331
  • Last Modified:

How to focus an item in a list control ?

How to set focus an item in a list control just like clicking on it ?
0
chongpeng
Asked:
chongpeng
1 Solution
 
V_BapatCommented:
Set state of the item 'nItem' using SetItemState().

m_list.SetItemState(nItem, LVIS_FOCUSED | LVIS_SELECTED, LVIF_STATE);

Vicky
0
 
vachoohoCommented:
CClistCtrl::SetSelectionMark(int);
0

Featured Post

2018 Annual Membership Survey

Here at Experts Exchange, we strive to give members the best experience. Help us improve the site by taking this survey today! (Bonus: Be entered to win a great tech prize for participating!)

Tackle projects and never again get stuck behind a technical roadblock.
Join Now