Problem using win32evtlogutil.ReportEvent()

Josef Sachs sachs at
Thu Aug 8 18:34:13 CEST 2002

I'm trying to do "custom event log writing"
(as per p. 360 of _Python Programming on Win32_) like so:

  self._svc_name_, # Application name
  servicemanager.PYS_SERVICE_STARTED, # Event ID
  0, # Event category
  (self._svc_name_, "") # The inserts

...but the description that I get in the event detail is:
The description for Event ID ( 4098 ) in Source ( Whatever ) could not
be found. It contains the following insertion string(s): Whatever, .

Has anyone gotten this to work?  Could you please post sample code?
I notice that this problem was posted in Dec 2000 and again this past
Jan-Feb, but I didn't see any solutions.

Thanks in advance.

More information about the Python-list mailing list