HTML Editor for ASP.NET AJAX Professional Edition
InsertCustomDialog Method (name, frameUrl, heading, height, width)
Server ReferenceWinthusiasm.HtmlEditorHtmlEditor..::.CreateDialogInfoEventArgsInsertCustomDialog(String, String, String, Int32, Int32)
Insert a custom dialog.
Declaration Syntax
C#
public void InsertCustomDialog(
	string name,
	string frameUrl,
	string heading,
	int height,
	int width
)
Parameters
name (String)
Name of the dialog.
frameUrl (String)
Absolute Url of the page displayed in the iframe of the dialog.
heading (String)
Dialog heading.
height (Int32)
Height of the dialog in pixels.
width (Int32)
Width of the dialog in pixels.
Remarks
The developer uses this method to add custom dialogs that may then be displayed by clicking on a custom button added through the CreateToolbarInfo event.

The dialog framework uses an iframe to display dialog content. The developer creates the iframe page and provides the Url to display, as well as the name, heading, height and width of the dialog.

The framework expects the following client-side API on the iframe page:

CopyC#
// Called by the framework when the dialog is displayed
// The framework behavior includes a reference to the editor
function Initialize(frameworkBehavior)

// Called by the framework when the OK button is clicked
function OnOK()

// Called by the framework when the dialog is closed
function OnClose()

Note: The onsubmit event for the form should also return false.

Examples
Sample iframe HTML page:
CopyC#
<html>
<head>
<title>My Dialog</title>
</head>
<body>
<form id="form1" action="MyDialog.htm" onsubmit="return false;">
    <div>My dialog content</div>
</form>
</body>

<script type="text/javascript">

var fx = null;

function Initialize(frameworkBehavior)
{
    // Store the reference 
    fx = frameworkBehavior;
}

function OnOK()
{
    // Do something
}

function OnClose()
{
    // Clean up
}

</script>

</html>

Assembly: Winthusiasm.HtmlEditor (Module: Winthusiasm.HtmlEditor) Version: 2.7.0.0 (2.7.0.0)