AppTaskInfo.Create(String, String, Uri, Uri, AppTaskContent) メソッド

定義

指定したパラメーターを使用して新しいアプリ タスクを作成します。

public:
 static AppTaskInfo ^ Create(Platform::String ^ title, Platform::String ^ subtitle, Uri ^ deepLink, Uri ^ iconUri, AppTaskContent ^ content);
/// [Windows.Foundation.Metadata.Experimental]
 static AppTaskInfo Create(winrt::hstring const& title, winrt::hstring const& subtitle, Uri const& deepLink, Uri const& iconUri, AppTaskContent const& content);
[Windows.Foundation.Metadata.Experimental]
public static AppTaskInfo Create(string title, string subtitle, System.Uri deepLink, System.Uri iconUri, AppTaskContent content);
function create(title, subtitle, deepLink, iconUri, content)
Public Shared Function Create (title As String, subtitle As String, deepLink As Uri, iconUri As Uri, content As AppTaskContent) As AppTaskInfo

パラメーター

title
String

Platform::String

winrt::hstring

タスクのタイトル。 この値は必須であり、関連するタスクをグループ化するために使用されます。

subtitle
String

Platform::String

winrt::hstring

追加のコンテキストを提供するタスクの省略可能なサブタイトル。 空の文字列を指定できます。

deepLink
Uri Uri

ユーザーがシェルでタスク表現をクリックしたときに、このタスクのコンテキストでアプリを起動する URI。

iconUri
Uri Uri

タスクを表すアイコンへのパス。

content
AppTaskContent

AppTaskContent ファクトリ メソッドのいずれかを使用して作成された、このタスクに表示する初期コンテンツ。

返品

タスクを表す新しい AppTaskInfo オブジェクト。

属性

注釈

Important

アプリ タスクのサポートは、2026 年 5 月から Windows 11 への段階的なロールアウトを開始します。 Windows.UI.Shell.Tasks API によって有効になるエクスペリエンスでは、対応するアプリ タスク機能が、アプリが実行されている Windows のバージョンに存在する必要があります。 それ以外の場合、これらの API は影響を受けなくなります。

タイトルは必須です。タイトルが指定されていない場合、このメソッドは例外をスローします。

適用対象

こちらもご覧ください