Вниз
Скачать: CL | DM;

Listview   Найти похожие ветки 

← →
Maksss   (2003-06-25 13:47) [0]

как сделать сортировку в листвиеве не по первой колонке, а по второй и т.д.


← →
Poirot ©   (2003-06-25 13:56) [1]

OnCompare + F1 - там всё описано!!!


← →
dataMaster ©   (2003-06-25 13:58) [2]

function CustomStringSortProc(Item1, Item2: TListItem; ParamSort: integer): integer; stdcall;
begin
result:=0;
if ParamSort=0 then
if (Item1.Caption)>(Item2.Caption) then Result :=1 else
if (Item1.Caption)<(Item2.Caption) then Result :=-1 else
else
if (Item1.SubItems[ParamSort-1])>(Item2.SubItems[ParamSort-1]) then Result :=1 else
if (Item1.SubItems[ParamSort-1])<(Item2.SubItems[ParamSort-1]) then Result :=-1;
end;

Использовать:
ListView1.CustomSort(@CustomStringSortProc, ColumnIndex);


← →
Maksss   (2003-06-25 14:37) [3]

пасибо



Страницы: 1 вся ветка

Скачать: CL | DM;



Память: 0.45 MB
Время: 0.009 c
14-20288
sapsi
2003-06-20 11:56
2003.07.07
Почему профессия программиста не считается вредной


14-20199
Тфьу
2003-06-21 17:11
2003.07.07
Кривой русский язык в Edit


3-19961
Lord Vader
2003-06-11 10:32
2003.07.07
Несколько копий одного QuickReport на одной странице


14-20213
Maksss
2003-06-22 07:07
2003.07.07
нюк


4-20365
4yguk
2003-05-04 19:43
2003.07.07
как функции-хуку общалься с прогой установившей хук?




   Наверх