メッセージとボタンを含む警告ダイアログを表示します。
以下に使用できます
モデル駆動型アプリ
構文
context.navigation.openAlertDialog(alertStrings, options)
パラメーター
| パラメーター名 | タイプ | 必須 | Description |
|---|---|---|---|
| alertStrings | AlertDialogStrings |
イエス | アラート ダイアログで使用する文字列。 AlertDialogStrings には、次の属性があります。 - text: string。 アラート ダイアログに表示されるメッセージ。 - confirmButtonLabel: string。 確認ボタン ラベルです。 ボタン ラベルを指定しない場合は、ボタン ラベルとして (ユーザーの優先言語で) OK が使用されます。 |
| options | AlertDialogOptions |
イエス | ダイアログ オプション。 AlertDialogOptions には、次の属性があります。 - height: number。 アラート ダイアログの高さ (ピクセル単位)。 - width: number。 アラート ダイアログの幅 (ピクセル単位) |
戻り値
タイプ: Promise
注釈
Example
context.navigation.openAlertDialog({text:"This is an alert.", confirmButtonLabel : "Yes",}).then(
function success()
{
document.getElementById("openAlertDialogButton")!.innerHTML = "Alert dialog closed";
},
function()
{
document.getElementById("openAlertDialogButton")!.innerHTML = "Error in Alert Dialog";
}
);
関連資料
Navigation
Power Apps コンポーネント フレームワーク API リファレンス
Power Apps コンポーネント フレームワークの概要