in reply to Reading win2000 application event logs with perl

You're only printing records with a source of "EventLog." There aren't any of those in the Application Log. I changed this:
if ($hashRef->{Source} eq "EventLog") { Win32::EventLog::GetMessageText($hashRef); print "Entry $x: $hashRef->{Message}\n"; }

to this:
#if ($hashRef->{Source} eq "EventLog") { Win32::EventLog::GetMessageText($hashRef); print "Entry $x: $hashRef->{Message}\n"; #}

and I got some output.
Dave

Replies are listed 'Best First'.
Re: Re: Reading win2000 application event logs with perl
by RichardH (Sexton) on Jun 12, 2001 at 21:15 UTC
    Thanks! This will put me back in the right direction!
      double check your logs, because when I run this program I dont get all of the events that are actually seen in the event viewer.