views:

24

answers:

1

I'm creating a service using the sc.exe command in windows xp

I want to save the STDOUT messages to svc.datetime.log

How do I do this?

I'm using a batch file as a wrapper to an executable. No heavy lifting or .NET

A: 

I would recommend using a logging framework like log4net or EntLib Logging Application Block to do this (assuming you're using .NET). There are a lot of pitfalls that you can run into if you're writing you're own, and existing frameworks do a good job.

Andy White
No I'm just using a batch file as a wrapper to an executable, no fancy .NET
codeninja
Ok, fair enough
Andy White