Here is a quick summary of the issue that I am currently having... I may be missing something obvious, but I have tried just about everything.
No matter what it try I can't seem to get it to work. At first i thought it was because they are both modal but now the radwindow is not and the radalert is... I have included a image of my result...
Sample Image
- I have a masterpage that has the windowmanager on it with the following definition:
<telerik:RadWindowManager ID="adminWindowManager" runat="server" DestroyOnClose="true" Behaviors="Close,Reload,Move" KeepInScreenBounds="true" Modal="true" VisibleStatusbar="false" ShowContentDuringLoad="false" OnClientPageLoad="ClientName.Web.UI.Window.OnWindowLoaded" /> - I have an aspx page that has a button that calls another page via radwindow:
<input type="button" onclick="ClientName.Web.UI.Window.OpenWindow('NewCustomer.aspx','NewCustomer',false);" value="New Customer" />
Supporting Functions:
ClientName.Web.UI.Window.Manager = function() { return GetRadWindowManager(); } ClientName.Web.UI.Window.OpenWindow = function(u, t, d, c) { var m = ClientName.Web.UI.Window.Manager(); var w = m.open(u, t); if (d) { w.set_modal(d); } if (c) { w.add_close(c); } }; - All of this works fine, then on the open aspx page i have a form with a validation summary. I edited two lines of the validationsummary javascript from msft to show a rad alert instead of modifing the innerhtml of the validationsummary.
- This is the function that it calls:
function ValidationSummaryOnSubmit(validationGroup) { ... ClientName.Web.UI.Window.OpenAlert('Validation HTML Message', 'Validation Error'); ... }
Supporting Functions:
ClientName.Web.UI.Window.GetParent = function() { var w = null; if (window.radWindow) { w = window.radWindow; } else if (window.frameElement.radWindow) { w = window.frameElement.radWindow; } return w.BrowserWindow; } ClientName.Web.UI.Window.OpenAlert = function(m, t) { var c = this; if (typeof radalert == 'undefined') { c = ClientName.Web.UI.Window.GetParent(); } var a = c.radalert(m, 0, 0, t); a.setActive(); // THIS DOES NOT WORK a.add_pageLoad(function(s,a) { ... }); // THIS DOES NOT WORK EITHER };
No matter what it try I can't seem to get it to work. At first i thought it was because they are both modal but now the radwindow is not and the radalert is... I have included a image of my result...
Sample Image