[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 322
  • Last Modified:

Directory.CreateDirectory issues

I have a two part question. If I am trying to access a non shared drive on a server such as
What is this called (the c$). Also it would appear that I can't programatically create a new directory at

Obviously if I went in and created a new directory and then shared it I could access it like

But I would rather be able to deal with the more ambiguous case using the c$ (I can't for the life of me remember what that is reffered to).

So anyway I am trying to programatically check to see if a directory exists at
, if it doesn't I want to create a new directory at the location

Any help (and the term that is used to describe drive access using that $) would be fantastic.

  • 2
1 Solution
You have to remember that the application will need admin rights to the c$ drive (no matter where it is located)
Also the call
Directory.Create will work as you plan...
Just remember to create your string:

NaananAuthor Commented:
Thanks, if the application is running under my credentials and I have admin access to the c$ drive then it should be all good correct?
But remember if it is running under someone elses it may fail...
If this is for your use only... no problem that I can see

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now