Application Life Cycle Of Windows Application

In this topic the lifecycle of a Universal Windows Platform (UWP) app is described, from the launched time till closing. Most of us like to use multiple applications at the same time. Users now expect your app to remember its state as they multitask on their device. For example, they expect the page to be scrolled to the same position and all of the controls to be in the same state as before. Here we will understand the application lifecycle of launching, suspending, and resuming.

This illustration represents the transitions between app execution states. We will describe these states and events in the next several sections.

execution states

Not running

Suppose you unlocked your phone and no application is running, every application is not in a running state. In not running stage application is not using any memory, any power of CPU and do not do any processes.

Running

After not running stage when you tap on an application and it starts; in other words it is launched. At this time application start to do calculations and uses memory and other resources. In simple words your application starts working.

Suspended

You launched your application and it is working correctly. Now you by mistake tap the Home Screen button. At this time as you press the button your application starts suspending, this is the stage when your application saves its states and position of UI and each and every calculation you performed before pressing the Home button. After every state is saved, your application goes in a suspended stage, application stops where it preserves its state.

In windows 5 applications can go to suspended state at the same time after that the first application is deactivated, it means application no more preserves it’s saved state and closed.

Resuming

When your application suspended and you want to again use your suspended app, you tap on the application and it will now go to resuming stage, application get its preserved state and provide all resources that is needed before start. After that phone resumed to that stage where you suspended your application.

Hope this will clear each and every thing in application life cycle.

Up Next
    Ebook Download
    View all
    Learn
    View all