dc

dc

  • NA
  • 663
  • 0

C# create folder structure and place files within folders created

Aug 28 2012 6:06 PM
I would like to accomplish the following tasks in a C#.net 2010 application:

1. start in a specified directory location.
2. check to see if a specified subfolder exists.
3. if the specified folder does not exist, create the subfolder called customer1.
4. if the subfolder  called 'docs' does not exist, create that folder.
5. if the type of document type is '*.pdf' or '*.doc' place the data file in the subfolder called
    'docs'.
    if the document type is of any other document type, place that document in folder level where called 'customer1'.

Thus I am wondering if you can tell me and/or point me to references that will show me how to accomplish all and/or parts of the steps I would like to accomplish listed above my showing me showing me code and/or pointing me to links that will show me how to accomplish this goal?

Answers (3)