disable and enable rows in CListCtrl

Is there a way you can disable and enable individual rows in CListCtrl.
Who is Participating?
In particular, this one (by MFC Superstar Chris Mauder) seems to allow disabling of rows:

    MFC Grid control (derived from CWnd)

-- Dan
Not directly.  You can do the ownerdraw thing to make them *look* disabled and then take action when the user tries to select one.  

Depending on your needs, you might be able to accomplish your goal by use the checkbox style -- as a kind of stand-in for enabled/not-enabled (checked/non-checked).

There are a number of CListCtrl-derived objects available that do that.  Try checking here
if you are intersted in using somebody elese ownerdraw logic.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.