Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Access to path denied?

Status
Not open for further replies.

jenlion

IS-IT--Management
Nov 13, 2001
215
VB.net 2008 service, trying to write a file to a directory on another server. I've tried both
Code:
Dim Filestrm As New FileStream(OutputPath, FileMode.Create, FileAccess.Write)
and a simple file copy after writing the file locally first; both get me an "Error 5: Access to the path '(outputpath here)' is denied.".

I've had the service logged in locally and logged in as a domain account that has full control of that destination folder. I've tried giving full control to NETWORK SERVICE on that directory. I can't tell why I'm not allowed to access this directory!

I am able to simply copy the file if I create it locally, logged in as that domain account to windows. I just can't do it programatically, and I need the *service* to do it.

What mysterious permission or setting needs changed so I can create this file in the proper location??
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top