i need to access Audit Failure
under Window log
-> Security
event instantly when it logs, is there any way to capture it instantly when it logs. i need to access real time attempts.
currently i am reading this from EventLogEntry
class in c#, but i need a my application to run when Audit Failure
occurs.
foreach (EventLogEntry entry in log.Entries)
{
if (entry.EntryType==EventLogEntryType.FailureAudit)
{
///
}
}
some thing similar to:
EventLog myNewLog = new EventLog();
myNewLog.Log = "MyCustomLog";
myNewLog.EntryWritten += new EntryWrittenEventHandler(MyOnEntryWritten);
myNewLog.EnableRaisingEvents = true;
Event log events, some like this i want to trigger windows log also