Application Object object
The Application object is used to initiate and control a Microsoft Management Console (MMC) session. You must create an Application object before using any other MMC 2.0 automation objects.
Members
The Application Object object has these types of members:
Events
The Application Object object has these events.
Event | Description |
---|---|
OnContextMenuExecuted | Occurs when a context menu is executed. |
OnDocumentClose | Occurs when a document is closed. |
OnDocumentOpen | Occurs when an MMC document is opened. |
OnListUpdated | Occurs when one or more list items are updated. |
OnNewView | Occurs when a view is added. |
OnQuit | Occurs when the MMC application is ended. |
OnSelectionChange | Occurs when the result item selection for a view is changed. |
OnSnapInAdded | Occurs when a snap-in has been added. |
OnSnapInRemoved | Occurs when a snap-in has been removed. |
OnToolbarButtonClicked | Occurs when a toolbar button is clicked. |
OnViewChange | Occurs when the view is changed. |
OnViewClose | Occurs when the view is closed. |
Methods
The Application Object object has these methods.
Method | Description |
---|---|
Help | Displays online Help for the console. |
Hide | Hides the application. |
Load | Loads a document from a specified file. |
Quit | Quits the MMC application. |
Show | Shows the application. |
Properties
The Application Object object has these properties.
Property | Access type | Description |
---|---|---|
Document |
Read-only |
Document object associated with the application. |
Frame |
Read-only |
Frame object for the application. |
UserControl |
Read/write |
UserControl setting for the application; determines whether the application is controlled by the user. |
VersionMajor |
Read-only |
Major version number of MMC. |
VersionMinor |
Read-only |
Minor version number of MMC. |
Visible |
Read-only |
Determines whether the application is visible (set by the Show or Hide method). |
Remarks
When your application starts MMC using the MMC 2.0 automation object model, a document and view are automatically created. OnDocumentOpen and OnNewView events will not be sent for the initial document and view, as MMC does not begin sending events until after the first view has been created. The OnDocumentOpen and OnNewView events aren't required during application startup, as the application can easily open a document (by calling the Application.Load method) or make a new view (by calling the Views.Add method). MMC sends your application the OnDocumentClose and OnViewClose events when the initial document and view are closed.
Requirements
Minimum supported client |
Windows Vista |
Minimum supported server |
Windows Server 2008 |
Header |
|
IDL |
|
CLSID |
CLSID_Application is defined as 49B2791A-B1AE-4C90-9B8E-E860BA07F889 |