S
Steve Roszko
Accessing Network Share with ASP.NET
FILESERVER1 (file server)
E:\WWWexport\
Shared as WWWExport
WEBSERVER2 (webserver)
I created virtual directory to
\\FILESERVER1\WWWExport\
When creating the virtual dir named "ReportExport" , I gave "connect as"
rights as a domain user with full rights to the share.
Response.Write(Server.MapPath("ReportExport"))
Returns
\\FILESERVER1\WWWExport
as expected.
IO.Directory.CreateDirectory(Server.MapPath("ReportsExport") & "\TEST")
Returns
Could not find a part of the path \\FILESERVER1\WWWExport.
Seems to be a permission thing of local ASPNET user, but why does it not
access the share as the domain user I specified the Connect As in the
virtual dir setup?
Is there any way to give the user WEBSERVER2\ASPNET permissions on
FILESERVER1 ?
It appears that I could solve this by specifying the impersonate user in
web.config but I don't want my entire app to run as that domain user.
Suggestions?
Thanks,
-Steve
--
Thanks for registering online with BikeReg.com!
-Steve Roszko
(e-mail address removed)
Pioneer Registration Services, LLC
Sport Specific Online Event Registration Services
www.BikeReg.com <http://www.BikeReg.com>
www.SkiReg.com <http://www.SkiReg.com>
www.RunReg.com <http://www.RunReg.com>
www.PioneerReg.com <http://www.PioneerReg.com>
FILESERVER1 (file server)
E:\WWWexport\
Shared as WWWExport
WEBSERVER2 (webserver)
I created virtual directory to
\\FILESERVER1\WWWExport\
When creating the virtual dir named "ReportExport" , I gave "connect as"
rights as a domain user with full rights to the share.
Response.Write(Server.MapPath("ReportExport"))
Returns
\\FILESERVER1\WWWExport
as expected.
IO.Directory.CreateDirectory(Server.MapPath("ReportsExport") & "\TEST")
Returns
Could not find a part of the path \\FILESERVER1\WWWExport.
Seems to be a permission thing of local ASPNET user, but why does it not
access the share as the domain user I specified the Connect As in the
virtual dir setup?
Is there any way to give the user WEBSERVER2\ASPNET permissions on
FILESERVER1 ?
It appears that I could solve this by specifying the impersonate user in
web.config but I don't want my entire app to run as that domain user.
Suggestions?
Thanks,
-Steve
--
Thanks for registering online with BikeReg.com!
-Steve Roszko
(e-mail address removed)
Pioneer Registration Services, LLC
Sport Specific Online Event Registration Services
www.BikeReg.com <http://www.BikeReg.com>
www.SkiReg.com <http://www.SkiReg.com>
www.RunReg.com <http://www.RunReg.com>
www.PioneerReg.com <http://www.PioneerReg.com>