wise_man
asked on
Right Align Column in CListCtrl
I'm trying to make my CListCtrl (LVS_REPORT) column right align by using:
LV_COLUMN lvColumn;
lvColumn.mask = LVCF_FMT | LVCF_WIDTH | LVCF_TEXT | LVCF_SUBITEM;
The problem is this method fail to set the first column to right align. All column except first column can be set.
Did any of you know what's going wrong ?
LV_COLUMN lvColumn;
lvColumn.mask = LVCF_FMT | LVCF_WIDTH | LVCF_TEXT | LVCF_SUBITEM;
The problem is this method fail to set the first column to right align. All column except first column can be set.
Did any of you know what's going wrong ?
ASKER
No, I don't want to change column order, I want to Left or Right Justify text inside the column.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Yes, owner draw will solve the problem, but is it really necessary ? why can't Microsoft make our live easier ?
ASKER
Yes, owner draw will solve the problem, but is it really necessary ? why can't Microsoft make our live easier ?
LPARAM is Address of an array that specifies the order in which columns should be displayed, in left-to-right order. For example, if the contents of the array are {2,0,1}, the control displays column 2, column 0, and column 1 in that order.
WPARAM is size, in elements, of the buffer at array. You can also use macro ListView_SetColumnOrderArr