Re: How to access a network share folder?

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance

From: GrantMagic (grant_at_magicalia.com)
Date: 09/13/04


Date: Mon, 13 Sep 2004 14:36:29 +0100

Have you tried using impersonate in the config file to make the application
impersonate a user on the other server, there by giving you permission to
write to the share

"Andrew Shitov" <andy@shitov.ru> wrote in message
news:%23tIvcBZmEHA.3060@TK2MSFTNGP14.phx.gbl...
>I have to copy files from one network share folder to another (both are on
>different remote machines). Server running this asp.net appllication is not
>configurable (except web.config), while network forlers requires passwords.
>
> The ideal solution would allow me to simply write File.Copy (from, to,
> true).
>
> I thought of two possibilities: either map a network folder inside the
> asp.net application or connect to the server that contail share.
>
> Trying to start 'net use' failed:
>
> System.Diagnostics.Process.Start ("net", @"use q: \\server\share$
> /user:name password");
>
> After this I still have the same drives as before calling 'net use'.
>
> What should I do? How to map a network drive? Or how to access a server
> (not changing the machine.config)?
>


Quantcast