From: Rick on
The following code returns a permission error:
Access to path "\\myServer\temp\test.txt" denied

source = "\\myServer\temp\test.txt"
dest = "c:\MyLocalMachine\test.txt"
System.IO.File.Copy(source, dest)

I am able to view files in "\\myServer\temp\test.txt" but do not have
permission to copy.
From: Cor Ligthert[MVP] on
Yes I agree with you, it is great that not everybody can simply attach to
your server without permission and that you can set that.



"Rick" <Rick(a)discussions.microsoft.com> wrote in message
news:6570B90E-1CD1-46C8-95DB-F02A6C437C44(a)microsoft.com...
> The following code returns a permission error:
> Access to path "\\myServer\temp\test.txt" denied
>
> source = "\\myServer\temp\test.txt"
> dest = "c:\MyLocalMachine\test.txt"
> System.IO.File.Copy(source, dest)
>
> I am able to view files in "\\myServer\temp\test.txt" but do not have
> permission to copy.

From: Patrice on
AFAIK, you have separate permissions to list the content of a directory and
to read the content of a file. Double check you have the appropriate
rights...

--
Patrice

"Rick" <Rick(a)discussions.microsoft.com> a �crit dans le message de groupe de
discussion : 6570B90E-1CD1-46C8-95DB-F02A6C437C44(a)microsoft.com...
> The following code returns a permission error:
> Access to path "\\myServer\temp\test.txt" denied
>
> source = "\\myServer\temp\test.txt"
> dest = "c:\MyLocalMachine\test.txt"
> System.IO.File.Copy(source, dest)
>
> I am able to view files in "\\myServer\temp\test.txt" but do not have
> permission to copy.