Sorted ListCtrl does not display Values correctly

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a dialog which contains a tree & list Control. On clicking, of tree item, the list ctrl list changes.
The list ctrl has 2 fields(Name & Value) & is of 'Report' Type.
The list ctrl data is filled from Objects of a class CMyCLass which consists of Members -Name & Value
Everything worked fine, but when i changed the List Ctrl with 'Sort Ascending' property checked, then the value displayed against the NAME is incorrect. If this 'Sort Ascending' Property is not set in RC , then, the behavior is correct.
Can anyone tell me what the reason can be
Thanks:)
 
I have a dialog which contains a tree & list Control. On clicking, of tree item, the list ctrl list changes.
The list ctrl has 2 fields(Name & Value) & is of 'Report' Type.
The list ctrl data is filled from Objects of a class CMyCLass which consists of Members -Name & Value.
Everything worked fine, but when i changed the List Ctrl with 'Sort Ascending' property checked, then the value displayed against the NAME is incorrect. If this 'Sort Ascending' Property is not set in RC , then, the behavior is correct.
Can anyone tell me what the reason can be?

Since you don't show your code, I can only guess that you're not using
the return value from InsertItem as the index when you set the
sub-item text.

Dave
 
Back
Top