Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All

Installer.BeforeUninstall Event

Occurs before the installers in the Installers property perform their uninstall operations.

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

public event InstallEventHandler BeforeUninstall

The following example demonstrates the BeforeUninstall event. It is raised by the OnBeforeUninstall method.

// MyInstaller is derived from the class 'Installer'.
MyInstaller() : base()
{
   BeforeUninstall += new InstallEventHandler(BeforeUninstallEventHandler);
}
private void BeforeUninstallEventHandler(object sender, InstallEventArgs e)
{
   // Add steps to perform any actions before the Uninstall process.
   Console.WriteLine("Code for BeforeUninstallEventHandler"); 
}

.NET Framework

Supported in: 4.6, 4.5, 4, 3.5, 3.0, 2.0, 1.1

.NET Framework Client Profile

Supported in: 4, 3.5 SP1
Show:
© 2015 Microsoft