Re: [python-win32] Python parser for Windows Event Logs

2009-07-17 Thread Tony Cappellini
Message: 3 Date: Thu, 16 Jul 2009 16:08:51 -0700 From: Tim Roberts t...@probo.com To: python-win32@python.org Subject: Re: [python-win32] Python parser for Windows Event Logs Message-ID: 4a5fb303.7010...@probo.com Content-Type: text/plain; charset=ISO-8859-1 Tony Cappellini wrote: I've added the

Re: [python-win32] python-win32 Digest, Vol 76, Issue 17

2009-07-17 Thread Tony Cappellini
Message: 2 Date: Thu, 16 Jul 2009 15:57:31 -0700 From: Tim Roberts t...@probo.com To: Python-Win32 List python-win32@python.org Subject: Re: [python-win32] Python parser for Windows Event Logs Message-ID: 4a5fb05b.2060...@probo.com Content-Type: text/plain; charset=ISO-8859-1 Would anyone be

Re: [python-win32] Python parser for Windows Event Logs

2009-07-17 Thread Tim Roberts
Tony Cappellini wrote: while 1: events=win32evtlog.ReadEventLog(hand,flags,0) if not events: break for event in events: print event.EventID, event.StringInserts then it all works as expected. This is what I'm doing. I have added the while 1 last week, after

Re: [python-win32] Python parser for Windows Event Logs

2009-07-17 Thread Tim Roberts
Tony Cappellini wrote: Similar. I saved one of the application event logs, and although Tim, would you try parsing the SystemEventLog (from Windows XP)? This is the one I'm having problems with, not the application log. It shouldn't make one whit of difference. The format of

Re: [python-win32] Python parser for Windows Event Logs

2009-07-17 Thread Tim Roberts
Tony Cappellini wrote: I've added the While loop Mark suggested but still see the same issue. GetNumberOfEventLogRecords() still returns 6 events, However the object returned from ReadEvenLog() still only contains 3 objects The next call to ReadeventLog() returns None I tried to send this

Re: [python-win32] python-win32 Digest, Vol 76, Issue 17

2009-07-17 Thread Tim Roberts
Tony Cappellini wrote: Tim, would you try parsing the SystemEventLog (from Windows XP)? This is the one I'm having problems with, not the application log. I saved a copy of my system event log with 2,383 events, and I'm able to read all 2,383 events. -- Tim Roberts, t...@probo.com

Re: [python-win32] Python parser for Windows Event Logs

2009-07-17 Thread Tony Cappellini
Ok- I've figured out the problem. After Mark suggested doing the call to ReadEventLog() inside of the while loop, I had accidentally left a call to ReadEventLog() outside of the loop. So the data coming back from that was just thrown away. The reason I didn't see that call is because all of