Questions tagged [eventcreate]

4 questions
8
votes
1 answer

New event log nowhere to be found after creating in PowerShell

Through PowerShell, I am attempting to create a new event log and write a test entry to it, but it is not showing up the Event Viewer. This is the command I'm using to create a new event log: new-eventlog -logname TestLog -source TestLog And to…
Matt
  • 291
  • 2
  • 9
4
votes
2 answers

EVENTCREATE fails with "ERROR: Access is denied" -- how to fix

I have also asked this question in a Microsoft Forum, but no answers there yet. I am in the process of building out a Windows 2012 server to replace a legacy Windows 2008 server. I am testing a legacy batch script that logs informational or system…
3
votes
2 answers

eventcreate with multiline description

I'd like to use eventcreate from a batch file to log the results of a file copy job (robocopy). What I'd really like to do is use the output of the file copy job as the description of the event (/D of createevent). The trouble is, there are…
0
votes
1 answer

Can you write to the category field in the event log?

I've written a simple batch script that watches some services and regularly restarts them. I've used the eventcreate command to write to the Windows event log, which seems like a good way of logging my actions, but I notice that the 'category'…
Colin Pickard
  • 1,261
  • 2
  • 16
  • 28