I am trying to register applications in a Windows event log in C # .net framework 4, but when I insert the log entries, the TimeCreated field (Event Viewer โ Windows Logs โ Application โ -> Details โ Friendly View โ System) gets a value similar to
[SystemTime] 2012-03-28T11:07:12.000000000Z
As you can see, the accuracy of the second second is absent, although I see some other event in the viewer, where there are numbers after the ".". with a more accurate timestamp.
Is this a kind of limitation of .Net Framework / CLR / C # or am I just doing something wrong?
Thanks.
VS2010SP1, Win7 / Server 2008 R2 Environment.
UPDATE:
I could mention that I tried with
EventLog.WriteEntry("applicationName", "message", logEntryType, (int)eventId, (short)taskCategory);
and log4net EventLogAppender.
UPDATE 2:
Thus, using ETW to insert events into the event log actually results in events in which SystemTime has secondary permission. Maybe this is actually necessary, it seems like an unnecessary case for my case.
source share