Re: File.Copy
- From: Peter Duniho <NpOeStPeAdM@xxxxxxxxxxxxxxxx>
- Date: Sat, 24 Nov 2007 01:01:54 -0800
On 2007-11-24 00:18:12 -0800, rgw1@xxxxxxxxxxx said:
Hello,
Can anyone help with this?
I am using C# with IIS 6.0 on Windows 2003 Server. I am trying to copy
a file over the network. It is attempting to copy a file on a NAS
(external hard drive), which is Linux based. I have already set the
permission on the NAS and I can copy files manually without any
problem. If I run the same code on IIS 5.1 on Windows XP on the same
network, it works!
When you are testing it on the other system, are you using the same exact user ID and password?
The exception looks like a straight permissions problem. Windows file security can be kind of quirky, so it's hard to say exactly without more information what a precise solution to a permissions problem would be (depending on the configuration of the network, you might need to have an exact NT domain account, or just log in with the right username and password, or provide the necessary credentials via "net use", or...).
But as a general rule, if you've got a system from which you can access the file, and one from which you can't, it's possible that you're just using different credentials on each system. Use the same working set of credentials on both, and it should work.
Of course, this means it doesn't really have anything to do with the C# code per se. But close enough. :)
Pete
.
- Follow-Ups:
- Re: File.Copy
- From: christery
- Re: File.Copy
- References:
- File.Copy
- From: rgw1
- File.Copy
- Prev by Date: Re: newbie question about data persistence
- Next by Date: Re: Getting form NameValueCollection from Html
- Previous by thread: File.Copy
- Next by thread: Re: File.Copy
- Index(es):
Relevant Pages
|