views:

19

answers:

0

Hey guys,

i want to log some traces in my service. When i set initializeData to a location in the d: partition, i can write with no problems. When i set the initializeData to c:\, it doesn't write at all. Now i was wondering 2 things :

1) Does my service not have the rights to write to c:\ partition?

2) if i don't specify the partition, where does it write to?

This is the part of my app.config which works:

<add initializeData="d:\txtServiceLog.txt" type="MonitoringServerService.FaultTracer, MonitoringServerService"
   name="txtListener" traceOutputOptions="DateTime, Timestamp, ProcessId, Callstack">
   <filter type="" />
</add>

When changing to code below, i doesn't write anymore :

<add initializeData="c:\txtServiceLog.txt" type="MonitoringServerService.FaultTracer, MonitoringServerService"
    name="txtListener" traceOutputOptions="DateTime, Timestamp, ProcessId, Callstack">
    <filter type="" />
</add>

And where should i look if i do this :

<add initializeData="txtServiceLog.txt" type="MonitoringServerService.FaultTracer, MonitoringServerService"
   name="txtListener" traceOutputOptions="DateTime, Timestamp, ProcessId, Callstack">
    <filter type="" />
</add>

Thanks in advance.