How to access on file system in WCF Service

1.3k Views Asked by At

Hi Experts I Have a WCF Service that Host it on IIS.I want to write something in a text file using my service but I get an exception :"Access denied on (file path)..."

how I can get access to file system? thanks

1

There are 1 best solutions below

0
RQDQ On BEST ANSWER

You have to give the account the IIS is running under write access to the directory or file you're trying to write to. Note that this can be a security risk (that's why IIS doesn't have permissions to do this by default).