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. C / C++ / MFC
  4. hide plus sign for empty folder in CTreeCtrl

hide plus sign for empty folder in CTreeCtrl

Scheduled Pinned Locked Moved C / C++ / MFC
data-structureshelp
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.
  • C Offline
    C Offline
    chetanjoshi9
    wrote on last edited by
    #1

    I am using CTreeCtrl ni my project. I am populating this tree with hard dis folder. There are some empty folders for which it is showing plus sign for expanding and nothing is happening when I click on plus sign. So please help me to hide that plus sign for empty folder in CTreeCtrl. Thank you.

    I 1 Reply Last reply
    0
    • C chetanjoshi9

      I am using CTreeCtrl ni my project. I am populating this tree with hard dis folder. There are some empty folders for which it is showing plus sign for expanding and nothing is happening when I click on plus sign. So please help me to hide that plus sign for empty folder in CTreeCtrl. Thank you.

      I Offline
      I Offline
      Iain Clarke Warrior Programmer
      wrote on last edited by
      #2

      TVS_HASBUTTONS
      Displays plus (+) and minus (-) buttons next to parent items. The user clicks the buttons to expand or collapse a parent item's list of child items. To include buttons with items at the root of the tree view, TVS_LINESATROOT must also be specified.

      I'm pretty sure that the sign is only shown when an item has children. Are you doing stranges things with I_CHILDRENCALLBACK? Try making a demo project, with a dialog, and just add a few boring items to it, and see if it behaves properly. If so, start looking at the differences. How are you populating the tree? Are you calling some function you haven't written, or are you using FindFirstFile/FindNextFile to get the file names to populate the tree with? Iain.

      Iain Clarke appears because CPallini still cares.

      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