Aldo Wrote concerning ListView properties (gridlines, fullrowselect):
there's a little quirk in the APIs here that I have overlooked.
ListView extended styles can not be set normally, but they require
instead a specific message (called LVM_SETEXTENDEDLISTVIEWSTYLE).
it will be solved with the next version.
if you can't live without it, here is a temporary workaround
found by inspecting the header files:
$LVM_SETEXTENDEDLISTVIEWSTYLE = 0x1000 + 54;
$LVS_EX_GRIDLINES = 0x001;
$LVS_EX_CHECKBOXES = 0x004;
$LVS_EX_TRACKSELECT = 0x008;
$LVS_EX_FULLROWSELECT = 0x020;
$Window->ListView->SendMessage(
$LVM_SETEXTENDEDLISTVIEWSTYLE,
0, $LVS_EX_GRIDLINES | $LVS_EX_FULLROWSELECT,
);
cheers,
Aldo
--------------------------
I got Gridlines and FullRowSelect to work. Aldo, thanks a bunch!
Attached is a new post of the generic DBGrid.pl application which now
implements gridlines and fullrowselect. If you have 1 or more ODBC
DataSourceNames(DSNs) setup pointing to any databases, try the DBGrid.pl
application. You can view Table rows and columns of data in a
scrollable/resizeable ListView control. I have puposely limited the sql
result set to pull only the first 1000 rows from the table you choose. If
you wish to raise that limit please do so in your personal copy. When you
click a row in the ListView, the whole row becomes highlighted, not just the
first column as was previously the case without fullrowselect implemented.
CODE IS ATTACHED
Regards,
Eric Hansen
DBGrid.pl