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. How to create new folder in VC++ MFC?

How to create new folder in VC++ MFC?

Scheduled Pinned Locked Moved C / C++ / MFC
c++tutorialquestion
4 Posts 4 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.
  • V Offline
    V Offline
    vandana7
    wrote on last edited by
    #1

    Also how to count no.of folders/no. of files? in VC++ MFC.

    I S H 3 Replies Last reply
    0
    • V vandana7

      Also how to count no.of folders/no. of files? in VC++ MFC.

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

      Use ::CreateDirectory (...) to create a folder. Or ::SHCreateDirectoryEx (...) to make a deep path of directories As for counting files, you'll have to use FindFirstFile / FindNextFile to get a list of files/directories in a directory. You can check the WIN32_FIND_DATA structures dwFileAttributes for a FILE_ATTRIBUTE_DIRECTORY flag to see if it's a directory. Good luck, Iain.

      1 Reply Last reply
      0
      • V vandana7

        Also how to count no.of folders/no. of files? in VC++ MFC.

        S Offline
        S Offline
        sw thi
        wrote on last edited by
        #3

        http://msdn2.microsoft.com/en-us/library/aa365522.aspx there you go.

        1 Reply Last reply
        0
        • V vandana7

          Also how to count no.of folders/no. of files? in VC++ MFC.

          H Offline
          H Offline
          Hamid Taebi
          wrote on last edited by
          #4

          Or you can use of dlgdirlist for get folder and file names and count.

          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