"helpful sql" <no****@stopspam.com> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
Hi all,
I dynamically generate Word Documents from my web application using
XmlDocument object and need to save them on a mapped network drive. I use
the Save method of XmlDocument object to save documents. Ican save them
successfully on local drive on web server. But when I try to save them on
a mapped network drive, I get permission denied errors. I made sure that
ASPNET had full access right in the folder where I need to save documents.
I also tried using UNC path, but that also does not work. Can someone
please point to what I may be doing wrong and explain the whole setup
process for being able to save documents from asp.net application?
Thanks in advance.
How did you manage to give aspnet access rights to a mapped network drive?
ASPNET is a local account, so it's not possible to grant right to this
account on another server!! (Note that ASPNET on one server is not the same
account as ASPNET on another server).
What you can do is impersonate a domain account in your web application. Or
much better "delegate" the document creation and writing to a COM+
(EnterpriseServices) server type application. This application could run
with domain account credentials valid to access the remote share, and can
implement fine grained access permissions through role membership.
Willy.