Jump to content
  • Advertisement


This topic is now archived and is closed to further replies.


Need help with ListView

This topic is 5936 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I''m using a ListView (CListCtrl) in an MFC app. The list has the following styles: LVS_EX_FULLROWSELECT | LVS_EX_HEADERDRAGDROP and view:report. The thing is that when the list losts focus the selected rows get deselected. Maybe not but the background color of the selected rows turns white when you click on a button and then you don''t know which row(s) that were selected. Any style constant I''ve forgotten?

Share this post

Link to post
Share on other sites
Found a way:

DWORD dwStyle = GetWindowLong(m_serverinfo.GetSafeHwnd(), GWL_STYLE);

Now the selected rows have grey background. Is it possible to use the blue "highlighted color" instead without ownerdraw?

Share this post

Link to post
Share on other sites

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!