Re: Kill Focus Rectangle!
I don't know if this is what you want, but here goes...
Set the ListView's LabelEdit property to lvwManual
In the ListView MouseUp event do "ListView1.StartLabelEdit"
Re: Kill Focus Rectangle!
But I don't want to give users the option to edit the labels associated with the images.
Arpan
Re: Kill Focus Rectangle!
Why do you want to do that for? It will not look very consistent with other applications if only the text gets highlighted.
Re: Kill Focus Rectangle!
Quote:
Why do you want to do that for? It will not look very consistent with other applications if only the text gets highlighted.
That's alltogether a different aspect, my dear penagate :)
Arpan
Re: Kill Focus Rectangle!
I fully agree with Penagate.
However, if you insist then add this. It's still somewhat less than optimal, but that's what you get if you want to go non-standard...
VB Code:
Private Sub ListView1_AfterLabelEdit(Cancel As Integer, NewString As String)
Cancel = True
End Sub
Re: Kill Focus Rectangle!
Ahhh... :D
You could use the _ItemClick event, which fires when an item is selected, and blit the icon image from the ImageList onto the ListView's DC - that should overwrite the "highlighted" image.
If you need any assistance with that I might be able to construct a quick example, that's assuming it works :D
1 Attachment(s)
Re: Kill Focus Rectangle!
Here you go - subclassing and BitBlt'ing wrapped into a module - tested and working.
HTH :)