Share via


AppInstance.IsCurrentInstance 속성

정의

앱의 현재 instance 이 instance 정의한 특정 키에 대해 앱의 등록된 instance 인지 여부입니다.

public:
 property bool IsCurrentInstance { bool get(); };
bool IsCurrentInstance();
public bool IsCurrentInstance { get; }
var boolean = appInstance.isCurrentInstance;
Public ReadOnly Property IsCurrentInstance As Boolean

속성 값

Boolean

bool

현재 앱이 앱의 등록된 instance 여부를 나타내는 부울입니다.

예제

다음 예제에서 찾은 instance 현재 instance 경우 해당 instance 활성화됩니다. 현재 instance 아닌 경우 이 예제는 찾은 앱 instance 리디렉션됩니다.

if (theInstance.IsCurrentInstance)
{
    global::Windows.UI.Xaml.Application.Start((p) => new App(activatedArgs));
}
else
{
    theInstance.RedirectActivationTo();
}

적용 대상