Re: Implementing HDS_DRAGDROP style of CHeaderCtrl



"neilsolent" wrote:
I want to activate the HDS_DRAGDROP style of CHeaderCtrl (which is
attached to my CListView).
However, I never call CHeaderCtrl::Create() because the creation is
done automatically when the CListView is created (so the code is
hidden from a novice like me). And CHeaderCtrl doesn't seem to have a
SetStyle() function that I can call later.

Has anyone got an example of how to do this please?


`CListCtrl' class has `SetExtendedStyle' method, which allows you to specify extended styles for list-view control. Alternatively, you can create `CListCtrl' instance with `CreateEx'. The style you need is `LVS_EX_HEADERDRAGDROP'.

HTH
Alex

.



Relevant Pages

  • Re: Capturing text from a CE control
    ... I tried getting the CEdit from the ... CListCtrl but it returned NULL. ... documentation on this control type. ... Keep in mind that if you are using CListView you have to ...
    (microsoft.public.vc.mfc)
  • Re: using the CListView
    ... Chris wrote: ... > instead go with CListView. ... > container for CListCtrl. ... control and use it to populate the control. ...
    (microsoft.public.vc.mfc)
  • Re: CListView and CListCtrl
    ... CListView is not derived from CListCtrl and you cannot use a CListView where ... a CListCtrl is expected. ... "Peter" wrote in message ... Dialog displays control and no ...
    (microsoft.public.vc.mfc)
  • Re: using the CListView
    ... > I decided to not try to use the CListCtrl directly in the splitter pane, ... > instead go with CListView. ... whatever CView wiring is necessary to make it work as a view. ... need to override anything to get up and running. ...
    (microsoft.public.vc.mfc)
  • Re: Relation between CListView and CListCtrl
    ... > achieve CListView,I want to know how to achieve CListCtrl in CListView,and ... CListView is a clever hack. ... so it acts like a CView. ... The CListCtrl is not a member, but it acts like a member that is ...
    (microsoft.public.vc.mfc)