I am trying to set the LVS_EX_FULLROWSELECT style on my grid list control as I want full row selection. However apparently it doesn't have any effect. Since I am using a number of other styles as well, I am wondering if LVS_EX_FULLROWSELECT has any compatibility issues with other styles. Anyone? Following are the styles I am setting.
Initially following styles are set on base list control class:
WS_CHILD|WS_BORDER|LVS_REPORT|LVS_SHOWSELALWAYS|LVS_SINGLESEL
Then I try to set additional styles in the derived grid list control class:
ListView_SetExtendedListViewStyleEx(sysId(), 0, LVS_EX_GRIDLINES | LVS_OWNERDATA | LVS_EX_FULLROWSELECT);
You need to send the LVM_
SETEXTENDEDLISTVIEWSTYLE
message to the control and specify theLVS_EX_FULLROWSELECT
extended style (source: MS Support).Edit:
Check the example. There is
Try using
ListView_GetExtendedListViewStyle(sysId())
instead of0
. BTW - does thissysId()
of yours really retrieve the window handle? The name sounds somewhat different.Cheers.