共用方式為


AppAction(String, String, String, String) 建構函式

定義

初始化 AppAction 類別的新執行個體。

public AppAction (string id, string title, string? subtitle = default, string? icon = default);
new Microsoft.Maui.ApplicationModel.AppAction : string * string * string * string -> Microsoft.Maui.ApplicationModel.AppAction
Public Sub New (id As String, title As String, Optional subtitle As String = Nothing, Optional icon As String = Nothing)

參數

id
String

用來回應動作點選的唯一標識符。

title
String

顯示在應用程式圖示上的可見標題。

subtitle
String

如果支援,則會顯示標題底下的子標題。

icon
String

標題旁顯示的圖示。

例外狀況

當或 titlenullid擲回 。

適用於