Re: Event log property doesn't retain setting changes..

From: KC (chhatra_at_hotmail.com)
Date: 02/11/04


Date: Wed, 11 Feb 2004 11:57:46 -0800

I thought, I would reply to this myself . Unless, any one of you have found
other wise, Turns out, you need to change the "maximum log size" setting as
well when you change the "overwrite" property. If you do so, it will retain
the changes. But, if you just change the "overwrite" options, it doesn't
retain it. This is only TRUE if you create your own "source" and "log".

"KC" <chhatra@hotmail.com> wrote in message
news:OHMlZmN7DHA.1460@tk2msftngp13.phx.gbl...
> Hi,
> I created a new event log source and log and user WriteEntry to enter the
> log as follows:
>
> ' Create the source, if it does not already exist.
> If Not EventLog.SourceExists("MySource") Then
> EventLog.CreateEventSource("MySource", "MyNewLog")
> End If
>
> ' Create an EventLog instance and assign its source.
> Dim myLog As New EventLog()
> myLog.Source = "MySource"
>
> ' Write an informational entry to the event log.
> myLog.WriteEntry("Writing to event log.")
>
> When I "Right Click" the log and change the property and close, it doesn't
> retain the change. For example; If I change the Log size property from
> "Overwrite in 7 days" to "Overwrite events when needed", it changes back
to
> "Overwrite in 7 days." etc..
> Am I doing something wrong in the code..
>
> Thanks in advance,
> KC
>
>
>
>



Relevant Pages

  • Re: Event log property doesnt retain setting changes..
    ... other wise, Turns out, you need to change the "maximum log size" setting as ... But, if you just change the "overwrite" options, it doesn't ... > I created a new event log source and log and user WriteEntry to enter the ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: Event log property doesnt retain setting changes..
    ... other wise, Turns out, you need to change the "maximum log size" setting as ... But, if you just change the "overwrite" options, it doesn't ... > I created a new event log source and log and user WriteEntry to enter the ...
    (microsoft.public.dotnet.languages.vb)
  • Re: Event log property doesnt retain setting changes..
    ... other wise, Turns out, you need to change the "maximum log size" setting as ... But, if you just change the "overwrite" options, it doesn't ... > I created a new event log source and log and user WriteEntry to enter the ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Security Login Full
    ... On the general tab set Maximum log size to ?? ... Select Overwrite events older than XX days and set it to ?? ...
    (microsoft.public.windowsxp.security_admin)
  • Re: Security Login Full
    ... On the general tab set Maximum log size to ?? ... Select Overwrite events older than XX days and set it to ?? ... The security log on this system is full. ...
    (microsoft.public.windowsxp.security_admin)