This documentation is archived and is not being maintained.

Installer::BeforeInstall Event

Occurs before the Install method of each installer in the installer collection has run.

Namespace:  System.Configuration.Install
Assembly:  System.Configuration.Install (in System.Configuration.Install.dll)

public:
 event InstallEventHandler^ BeforeInstall {
	void add (InstallEventHandler^ value);
	void remove (InstallEventHandler^ value);
}

The following example demonstrates the BeforeInstall event. It is raised by the OnBeforeInstall method.


   // MyInstaller is derived from the class 'Installer'.
private:
   MyInstaller()
   {
      BeforeInstall += gcnew InstallEventHandler( this, &MyInstaller::BeforeInstallEventHandler );
   }

   void BeforeInstallEventHandler( Object^ sender, InstallEventArgs^ e )
   {
      // Add steps to perform any actions before the install process.
      Console::WriteLine( "Code for BeforeInstallEventHandler" );
   }


.NET Framework

Supported in: 4, 3.5, 3.0, 2.0, 1.1, 1.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1

Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows XP SP2 x64 Edition, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.
Show: