ContactPanelActivatedEventArgs ContactPanelActivatedEventArgs ContactPanelActivatedEventArgs ContactPanelActivatedEventArgs Class

Definition

Provides data when an app is activated because it uses the Contact Panel.

public : sealed class ContactPanelActivatedEventArgs : IActivatedEventArgs, IActivatedEventArgsWithUser, IContactPanelActivatedEventArgspublic sealed class ContactPanelActivatedEventArgs : IActivatedEventArgs, IActivatedEventArgsWithUser, IContactPanelActivatedEventArgsPublic NotInheritable Class ContactPanelActivatedEventArgs Implements IActivatedEventArgs, IActivatedEventArgsWithUser, IContactPanelActivatedEventArgs// You can use this class in JavaScript.
Attributes
Windows 10 requirements
Device family
Windows 10 Creators Update (introduced v10.0.15063.0)
API contract
Windows.Foundation.UniversalApiContract (introduced v4)

Properties

Contact Contact Contact Contact

Gets the selected contact from the Contact Panel.

public : Contact Contact { get; }public Contact Contact { get; }Public ReadOnly Property Contact As Contact// You can use this property in JavaScript.
Value
Contact Contact Contact Contact

The selected contact.

Examples

protected async override void OnActivated(IActivatedEventArgs args)
{

    if (args.Kind == ActivationKind.ContactPanel)

    {

        // At this point, ContactPanelActivatedEventArgs.Contact

        // is an empty Contact.  Only its Id property is set.

        ContactPanelActivatedEventArgs panelArgs = (ContactPanelActivatedEventArgs)args;



        // To get access to all of the Contact's property data, you must

        // use the Id to re-retrieve the Contact from the ContactStore.

        ContactStore store = await ContactManager.RequestStoreAsync(ContactStoreAccessType.AppContactsReadWrite);

        Contact contact = await store.GetContactAsync(panelArgs.Contact.Id);



        // Now you have a fully populated Contact to work with.

    }

}

Remarks

The selected contact will be an empty contact with only its Id property set. You must use this Id to re-retrieve the contact from the ContactStore in order to get access to the rest of the contact's property data.

ContactPanel ContactPanel ContactPanel ContactPanel

Gets the contact panel.

public : ContactPanel ContactPanel { get; }public ContactPanel ContactPanel { get; }Public ReadOnly Property ContactPanel As ContactPanel// You can use this property in JavaScript.

Kind Kind Kind Kind

Gets the activation type.

public : ActivationKind Kind { get; }public ActivationKind Kind { get; }Public ReadOnly Property Kind As ActivationKind// You can use this property in JavaScript.

PreviousExecutionState PreviousExecutionState PreviousExecutionState PreviousExecutionState

Gets the execution state of the app before it was activated.

public : ApplicationExecutionState PreviousExecutionState { get; }public ApplicationExecutionState PreviousExecutionState { get; }Public ReadOnly Property PreviousExecutionState As ApplicationExecutionState// You can use this property in JavaScript.

SplashScreen SplashScreen SplashScreen SplashScreen

Gets the splash screen object, which provides information about the transition from the splash screen to the activated app.

public : SplashScreen SplashScreen { get; }public SplashScreen SplashScreen { get; }Public ReadOnly Property SplashScreen As SplashScreen// You can use this property in JavaScript.
Value
SplashScreen SplashScreen SplashScreen SplashScreen

The object that provides splash screen information.

User User User User

Gets the user the app was activated for.

public : User User { get; }public User User { get; }Public ReadOnly Property User As User// You can use this property in JavaScript.
Value
User User User User

The user the app was activated for.