Hi!
If a ListView control losts focus the background color of the selected item changes. It gets the same color as a not selected item.
Can I avoid this behavior?
Best regards
Timm
In order for this site to work correctly we need to store a small file (called a cookie) on your computer. Most every site in the world does this, however since the 25th of May 2011, by law we have to get your permission first. Please abandon the forum if you disagree.
Para que este foro funcione correctamente es necesario guardar un pequeño fichero (llamado cookie) en su ordenador. La mayoría de los sitios de Internet lo hacen, no obstante desde el 25 de Marzo de 2011 y por ley, necesitamos de su permiso con antelación. Abandone este foro si no está conforme.
Para que este foro funcione correctamente es necesario guardar un pequeño fichero (llamado cookie) en su ordenador. La mayoría de los sitios de Internet lo hacen, no obstante desde el 25 de Marzo de 2011 y por ley, necesitamos de su permiso con antelación. Abandone este foro si no está conforme.
ListView
- ignacio
- Site Admin
- Mensajes: 9254
- Registrado: Lun Abr 06, 2015 8:00 pm
- Ubicación: Madrid, Spain
- Contactar:
Re: ListView
Hello Timm,
Try this trick:
- Set Listview:lShowSelAlways to .F.
- Add this event:
Regards,
Try this trick:
- Set Listview:lShowSelAlways to .F.
- Add this event:
Código: Seleccionar todo
METHOD ListView1DrawCell( oSender, oItem, nColumn, nClrText, nClrPane, hDC, aRect ) CLASS TForm1
LOCAL oFocusItem
oFocusItem := ::oListView1:GetFocused()
IF oFocusItem <> NIL .and. oItem == oFocusItem
nClrText := CLR_HGREEN
nClrPane := CLR_GREEN
RETURN 1
ENDIF
RETURN NIL
Re: ListView
Hi Ignacio,
in Xailer 4 TListViewItem seems not to have the event OnDrawCell.
Is only part of Xailer 5, right? -> http://xailer.info/wordpress/en/?p=304
Could it be that Xailer 5 is already available and you just forgot to sent it to me? Just kidding...
Best regards
Timm
in Xailer 4 TListViewItem seems not to have the event OnDrawCell.
Is only part of Xailer 5, right? -> http://xailer.info/wordpress/en/?p=304
Could it be that Xailer 5 is already available and you just forgot to sent it to me? Just kidding...
Best regards
Timm