Logs Event Logs Monitor Event Logs in Real Time , WMI
' Monitor Event Logs in Real Time
strComputer = "." Set objWMIService = GetObject("winmgmts:" _ & "{impersonationLevel=impersonate, (Security)}!\\" & _ strComputer & "\root\cimv2")
Set colMonitoredEvents = objWMIService.ExecNotificationQuery _ ("Select * from __instancecreationevent where " _ & "TargetInstance isa 'Win32_NTLogEvent' " _ & "and TargetInstance.EventCode = '533' ")
Do Set objLatestEvent = colMonitoredEvents.NextEvent strAlertToSend = objLatestEvent.TargetInstance.User _ & " attempted to access DatabaseServer." Wscript.Echo strAlertToSend Loop
|
VbsEdit includes all these samples!
Download Now!
Version 5.4.1 - This package includes VbsEdit 32-bit, VbsEdit 64-bit, HtaEdit 32-bit and HtaEdit 64-bit. The evaluation version never expires.
Home
Buy Now
HtaEdit
Support
Video
What's new ?
|