Page.DisplayActionSheet(String, String, String, String[]) 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
顯示原生平台動作工作表,讓應用程式使用者可從數個按鈕之中選擇。
public System.Threading.Tasks.Task<string> DisplayActionSheet(string title, string cancel, string destruction, params string[] buttons);
member this.DisplayActionSheet : string * string * string * string[] -> System.Threading.Tasks.Task<string>
參數
- title
- System.String
所顯示動作工作表的標題。 必須不是 null。
- cancel
- System.String
要在 [取消] 按鈕中顯示的文字。 可以是 null,隱藏取消動作。
- destruction
- System.String
要在 [解構] 按鈕中顯示的文字。 可以是 null,隱藏解構選項。
- buttons
- System.String[]
其他按鈕的文字標籤。 必須不是 null。
傳回
System.Threading.Tasks.Task<System.String>
可等候的工作,會顯示動作工作表,並傳回使用者所按按鈕的文字。
備註
開發人員應該注意 Windows 的行尾結束符 CR-LF,只能在 Windows 系統上運作,而且與 iOS 和 Android 不相容。 其中一個特別的結果是,在CR-LF之後出現的字元 (例如,title.) 可能不會顯示在非 Windows 平臺上。 開發人員必須針對每個目標系統使用正確的行尾結束符。