BaseForm Class

Definition

Provides a base class for forms, specifying a service provider and a method that indicates when a form is first activated.

public ref class BaseForm abstract : System::Windows::Forms::Form
public abstract class BaseForm : System.Windows.Forms.Form
type BaseForm = class
    inherit Form
Public MustInherit Class BaseForm
Inherits Form
Inheritance
BaseForm
Derived

Notes to Implementers

When you inherit from BaseForm, you must override the following members: ShowHelp() and Update().

Constructors

BaseForm(IServiceProvider)

When overridden in a derived class, initializes a new instance of the BaseForm class.

Properties

CanShowHelp

Gets a value indicating whether the context-sensitive Help button is shown.

ServiceProvider

Gets the service object for the class.

Methods

DisplayErrorMessage(Exception, ResourceManager)

Displays the error message from the exception thrown by the IServiceProvider interface.

Dispose(Boolean)

Releases the unmanaged resources used by the BaseForm and optionally releases the managed resources.

GetService(Type)

Retrieves the requested service.

OnActivated(EventArgs)

Occurs when the base form is activated.

OnHelpRequested(HelpEventArgs)

Occurs when a Help control is activated.

OnInitialActivated(EventArgs)

Occurs when the base form is first activated.

ShowError(Exception, String, Boolean)

Displays the specified exception and information about the exception in a message box.

ShowHelp()

When overridden in a derived class, displays the Help file.

ShowMessage(String)

Displays a message box that uses the specified text.

ShowMessage(String, MessageBoxButtons, MessageBoxIcon, MessageBoxDefaultButton)

Displays a message box that uses the specified text, button set, symbol, and default button.

Update()

When overridden in a derived class, updates the view of the form.

WndProc(Message)

Reroutes the context-sensitive Help button events to the ShowHelp() method.

Applies to