Generic.EventLogManager' does not contain a definition for 'Installers'

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • baburk
    New Member
    • Oct 2006
    • 111

    Generic.EventLogManager' does not contain a definition for 'Installers'

    Hi all,

    Iam getting this errormessage when i called this function.

    This function is for to log the error message.

    Generic.EventLo gManager' does not contain a definition for 'Installers' D:\TravelSoln\A pp_Code\Generic \EventLog.cs

    Iam having this namespace
    Code:
    using System.Configuration.Install;
    using System.Diagnostics;
    using System.ComponentModel;
    
        public class EventLogManager
        {
    
            private EventLogInstaller myEventLogInstaller;
    
            public void MyEventLogInstaller()
            {
                // Create an instance of 'EventLogInstaller'.
                myEventLogInstaller = new EventLogInstaller();
                // Set the 'Source' of the event log, to be created.
                myEventLogInstaller.Source = "MyNewLog";
                // Set the 'Log' that the source is created in.
                myEventLogInstaller.Log = "MyNewLog";
                // Add myEventLogInstaller to 'InstallerCollection'.
                this.Installers.Add(myEventLogInstaller);
    
            }
    
    }
    Please help me to overcome this problem.
    Last edited by Plater; May 21 '08, 07:51 PM. Reason: code tags
  • Plater
    Recognized Expert Expert
    • Apr 2007
    • 7872

    #2
    Looks pretty clear to me.
    You're calling this.Installers , but clearly your EventLogManager class does not contain a definitions for Installers

    Comment

    Working...