Конференция "KOL" » ListView & GroupView
 
  • ParanoiS © (30.09.14 17:15) [0]
    Как реализовать сие? Пытался из VCL вытащить, всё вроде бы должно работать, но...

    Пытался также делать ->

    -----------------------------

    up vote
    2
    down vote
    accepted
    Enable the group view on the listview before adding the group to the listview. You can use the ListView_EnableGroupView  macro or the LVM_ENABLEGROUPVIEW message to achieve this.

    The listview must have the top alignment window style. You can set this style in the resource editor for the listview control or apply it using LVS_ALIGNTOP .

    The group must have items associated with it. If the group does not have any items associated it may not show. When inserting an item into the listview you must specify the group id using LVITEM's iGroupId property. Note that the iGroup property of LVITEM  is read-only and should not be used for specifying which group an item belongs to.

    The group must have items associated with it in order for it to show. If you are setting an item's group after both the item and the group have been created make sure that you are not using the ListView_MoveItemToGroup  macro which is only available on Windows CE. Instead you can set the item's group using the ListView_SetItem macro.

    LVITEMA Item = {0};

    Item.mask = LVIF_GROUPID;
    Item.iItem = Index;
    Item.iGroupId = GroupId;

    if (ListView_SetItem(hWnd, &Item) == FALSE)
       return FALSE;
    return TRUE;
    The listview cannot be in "List" mode as it is unsupported.

    The listview cannot be an ownerdrawn listview it is also unsupported.

    The application manifest  must specify version 6.0 or higher of the common controls library.

    Ensure that when you call InitCommonControlsEx you do not include the ICC_LISTVIEW_CLASSES flag as in some cases it might prevent the listview control from displaying groups.

    Additional resources:

    Arranging List Items by Group
    The ListView grouping feature (in Windows XP)
    Enabling Visual Styles

    ----------------------------

    тоже не работает...
  • ParanoiS © (09.10.14 10:15) [1]
    усё, вопрос закрыт... есть даже юнит, если кому надо
  • RusSun © (09.10.14 17:02) [2]
    Можно на почту? Заранее спасибо)
  • Addienasa (25.11.15 03:15) [3]
    Удалено модератором
 
Конференция "KOL" » ListView & GroupView
Есть новые Нет новых   [118640   +44][b:0][p:0]