writing to a file from a dll

K

Kristof Thys

Hello,

I'm writing a webservice in ASP.net, wich uses a dll. In this dll I'm
trying to write to a temporary file. But this does not seem to work.
When I build the dll as an exe it works perfect.
Is there something wrong with write permissions, and where should I
adjust this?


grtz,


Kristof
 
N

nyousfi

Hi

The website runs under a predefined username which can be changed.
The account it runs under is normally a very ristricted account and
therefore cannot do the same things an EXE can do.

Try the following

1. You can give this account more permissions
2. Give the account read/write access to the log file

However, if it's just logging you're after then I would suggest you
use the event log.

Good luck
 
S

Scott Allen

Quite possibly it is a permissions issue. Are you getting an exception
or error code? Does the ASPNET account (NETWORK SERVICE account in IIS
6) have write permissions on the directory?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,432
Messages
2,571,682
Members
48,796
Latest member
Greg L.

Latest Threads

Top