Search
Dialogs.showInfoDialog Method
See Also
 






Shows an info dialog, which displays a message and an OK button.

Namespace: MindFusion.Common.UI
File: Dialogs.js

 Syntax

JavaScript  Copy Code

function showInfoDialog ([title, [message, [callback, [parentElement, [theme]]]]])

 Parameters

title
Optional.

String. The text to display as a dialog title.

message
Optional.

String. The message to display as the dialog text.

callback
Optional.

function. The callback function to invoke when the dialog is closed.

parentElement
Optional.

HTMLElement. The Dom element to append the dialog to.If the parameter is not specified, the dialog will be appended to document.body.

theme
Optional.

String. The theme of the dialog.

 Example

The following code creates an info dialog:

JavaScript  Copy Code

var infoMessage; = "";

function informUser(elapsedTime)
{
   var infoMessage = "You have played this game for " + elapsedTime + "minutes!;
 // show the dialog
 ui.Dialogs.showInfoDialog("Elapsed Time", infoMessage, informUser,           document.getElementById("content"), "standard");
 
}

 See Also