10.1.3 Application

(usage)

<Application />

(description)

Encapsulates an application.

[types assignable to]

Application x:Object

(used by)

Application

(properties)

MainWindow

Window

(description)

The main window of the application.

Resources

ResourceDictionary

(description)

A collection of application-scope resources, such as styles and brushes.

ShutdownMode

ShutdownMode

(description)

The condition that causes the Shutdown method to be called.

StartupUri

x:Uri

(description)

A UI that is automatically shown when an application starts.

(static properties)

Current

Application

(description)

The Application object for the current AppDomain.

ResourceAssembly

Assembly

(description)

The Assembly that provides the pack uniform resource identifiers (URIs) for resources in an application.

(events)

Activated

Occurs when an application becomes the foreground application.

Deactivated

Occurs when an application stops being the foreground application.

DispatcherUnhandledException

Occurs when an exception is thrown by an application but not handled.

Exit

Occurs just before an application shuts down, and cannot be canceled.

FragmentNavigation

Occurs when a navigator in the application begins navigation to a content fragment, Navigation occurs immediately if the desired fragment is in the current content, or after the source XAML content has been loaded if the desired fragment is in different content.

LoadCompleted

Occurs when content that was navigated to by a navigator in the application has been loaded, parsed, and has begun rendering.

Navigated

Occurs when the content that is being navigated to by a navigator in the application has been found, although it may not have completed loading.

Navigating

Occurs when a new navigation is requested by a navigator in the application.

NavigationFailed

Occurs when an error occurs while a navigator in the application is navigating to the requested content.

NavigationProgress

Occurs periodically during a download that is being managed by a navigator in the application to provide navigation progress information.

NavigationStopped

Occurs when the StopLoading method of a navigator in the application is called, or when a new navigation is requested by a navigator while a current navigation is in progress.

SessionEnding

Occurs when the user ends the Windows session by logging off or shutting down the operating system.

Startup

Occurs when the Run method of the Application object is called.