Manoj Bisht

Manoj Bisht

  • NA
  • 145
  • 0

Move content from one directory into another directory

Jan 7 2008 4:34 AM
Hello Friends,

I want to copy the contents(subdirectories and files) from source folder into destination folder.

Here is my code ...........

DirectoryInfo dir=new DirectoryInfo(MapPath(".")+"\\"+"Images");
dir.MoveTo(MapPath(".")+"\\"+"Hello");



and also I've set <identity impersonate="true" /> in web.config

The error i'm getting is given below...

Access to the path "c:\inetpub\wwwroot\Rough\Images" is denied

Answers (1)