CListCtrl LVN_ITEMCHANGING - Page 2
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Page 2 of 2 FirstFirst 12
Results 16 to 18 of 18

Thread: CListCtrl LVN_ITEMCHANGING

  1. #16
    Join Date
    Oct 2012
    Posts
    9

    Re: CListCtrl LVN_ITEMCHANGING

    Personally, I am trying to prevent the selected item from being changed. The code does exactly what I want it to do. I did have to change one small piece:

    FROM:
    if ( pNMListView->uOldState == LVIS_FOCUSED ) {

    TO:
    if ( pNMListView->uOldState == LVIS_SELECTED ) {

  2. #17
    Join Date
    Jun 2002
    Location
    Stockholm, Sweden
    Posts
    1,597

    Re: CListCtrl LVN_ITEMCHANGING

    I replied in your other thread, basically you should not change any selection or focus in the handler code for LVN_ITEMCHANGING. Instead use SetTimer() to make the changes after the handler has completed.
    Nobody cares how it works as long as it works

  3. #18
    Join Date
    Oct 2012
    Posts
    9

    Re: CListCtrl LVN_ITEMCHANGING

    Quote Originally Posted by zerver View Post
    Nobody cares how it works as long as it works
    I completely agree and my code works for my situation.

Page 2 of 2 FirstFirst 12

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Azure Activities Information Page

Windows Mobile Development Center


Click Here to Expand Forum to Full Width

This is a CodeGuru survey question.


Featured


HTML5 Development Center