I am writting a code to disable selcted items in LISTBOX.
i.e I want to show item in list but don’t want user to select it.
As shown in image below. Or similar image in link.
Is it possible in VB6 ?
Please help.

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You can’t do this with a ListBox without serious owner-draw fun. However, you could do it with a list view control.
The closest I have done to this is to change the forecolor of disabled list items, and intercepted item click events so that the item is unselected. The Tag property of the list item is used to store the “disabled” state.
I ought to mention that I couldn’t get this code to prevent the item from being “selected” whilst the mouse button is done. To do this, you would have to do some subclassing.
The following class “ListViewWrapper” should be added to the project:
It should be used like this: