Accessing shared folder over a network in windows service

后端 未结 1 1810
时光说笑
时光说笑 2021-01-22 22:01

I have a windows service that needs to access the files (sometime modification also) from a network (shared folder). I get the file name from an XML like,

<         


        
相关标签:
1条回答
  • 2021-01-22 22:51

    Most likely, the problem is in permissions to the shared folder. Your service runs under some user account and this account needs to have access granted to that folder. In case it's the 'Local Service' account you won't be able to access it. Just check under what account you run the service and whether it has access to that folder.

    UPDATE: See this MSDN article for how to debug windows service applications.

    0 讨论(0)
提交回复
热议问题