Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Managed C++/CLI
  4. I Need to make the CListCtrl non sortable at run time

I Need to make the CListCtrl non sortable at run time

Scheduled Pinned Locked Moved Managed C++/CLI
algorithmsjsonhelp
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Offline
    J Offline
    Javed Akhtar Ansari
    wrote on last edited by
    #1

    Hi Dear, I need to make the report view of the list control non sortable( Disable Sorting) at run time. But i could not find out any API. Can Any body help me:(

    S 1 Reply Last reply
    0
    • J Javed Akhtar Ansari

      Hi Dear, I need to make the report view of the list control non sortable( Disable Sorting) at run time. But i could not find out any API. Can Any body help me:(

      S Offline
      S Offline
      sps itsec46
      wrote on last edited by
      #2

      Hi! CListCtrl sounds like MFC (i.e. unmanaged), so I guess you've asked this question in the wrong forum. Try here: Visual C++ / MFC[^] But wait... try if this answers your question:

      CListCtrl yourListCtrl;

      ...

      CHeaderCtrl* pHeader = yourListCtrl.GetHeaderCtrl();
      if(pHeader)
      {
      // (1) do this to enable header push buttons
      pHeader->ModifyStyle(0, HDS_BUTTONS);

      // (2) do this to disable header push buttons
      pHeader->ModifyStyle(HDS_BUTTONS, 0);
      }

      cheers, mykel OMM: "Let us be thankful we have an occupation to fill. Work hard, increase production, prevent accidents and be happy."

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups