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. which function counts the number of directories?

which function counts the number of directories?

Scheduled Pinned Locked Moved C / C++ / MFC
helpquestion
4 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.
  • G Offline
    G Offline
    Geert Craessaerts
    wrote on last edited by
    #1

    Can anyone help me to find a function that counts the number of directories? I've tried it with the _findnext function but obviously it only works for counting the number of files and not the directories. Thanx a lot! Kind regards, Geert

    T 1 Reply Last reply
    0
    • G Geert Craessaerts

      Can anyone help me to find a function that counts the number of directories? I've tried it with the _findnext function but obviously it only works for counting the number of files and not the directories. Thanx a lot! Kind regards, Geert

      T Offline
      T Offline
      Ted Ferenc
      wrote on last edited by
      #2

      look at the definition of struct _finddata_t the attrib member


      If I have seen further it is by standing on the shoulders of Giants. - Isaac Newton 1676

      G 1 Reply Last reply
      0
      • T Ted Ferenc

        look at the definition of struct _finddata_t the attrib member


        If I have seen further it is by standing on the shoulders of Giants. - Isaac Newton 1676

        G Offline
        G Offline
        Geert Craessaerts
        wrote on last edited by
        #3

        Does this also work for directories? Thanx, Geert

        T 1 Reply Last reply
        0
        • G Geert Craessaerts

          Does this also work for directories? Thanx, Geert

          T Offline
          T Offline
          Ted Ferenc
          wrote on last edited by
          #4

          yes, look at the MSDN, it says _A_SUBDIR Subdirectory. Value: 0x10 Or use FindFirstFile


          If I have seen further it is by standing on the shoulders of Giants. - Isaac Newton 1676

          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