Jon,
The above solution will not work.
CType(oCuteEditor.ToolControls("New").Control, System.Web.UI.WebControls.WebControl).Attributes.Add("onclick", "return ConfirmWindow(""Are you sure you want to clear this document??\nSelect 'OK' to delete or 'Cancel' to quit."");")
The above code will ovewrite the 'onclick' event of the "New" button.
I suggest you create a new custom button to handle this.
<script language="javascript">
<!--
function ConfirmWindow(strDialogMessage){
var strMessage;
var intResponse;
intResponse = confirm(strDialogMessage);
if (intResponse == 1) {
// get the cute editor instance
var editor1 = document.getElementById('<%=Editor1.ClientID%>');
editor1.ExecCommand("New");
return true;
} else {
return false;
}
}
//-->
</script>
asp.net Chat http://cutesoft.net/ASP.NET+Chat/default.aspx
Web Messenger: http://cutesoft.net/Web-Messenger/default.aspx
asp.net wysiwyg editor: http://cutesoft.net/ASP.NET+WYSIWYG+Editor/default.aspx
asp wysiwyg html editor: http://cutesoft.net/ASP
asp.net Image Gallery: http://cutesoft.net/ASP.NET+Image+Gallery/default.aspx
Live Support: http://cutesoft.net/live-support/default.aspx