This is a migrated thread and some comments may be shown as answers.

RadAlert Won't Display On Top Of RadWindow

2 Answers 174 Views
Window
This is a migrated thread and some comments may be shown as answers.
Marc Messer
Top achievements
Rank 2
Marc Messer asked on 10 Aug 2009, 09:38 PM
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. 

  1. 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"  /> 
  2. 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); } 
    }; 
  3. 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.
  4. 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   

2 Answers, 1 is accepted

Sort by
0
Accepted
Georgi Tunev
Telerik team
answered on 11 Aug 2009, 06:34 AM
Hi Marc,

Try calling a.setActive(true); with a small timeout and see how your logic will behave. If you still experience problems after that, please open a support ticket and send us a small sample project where this issue could be reproduced. Just make sure that the project can be run locally and attach it to the ticket - we will check it right away.



All the best,
Georgi Tunev
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Marc Messer
Top achievements
Rank 2
answered on 11 Aug 2009, 02:24 PM
The set timeout worked... however it would be nice to have the ability to attach load functions etc.. make sense?
Tags
Window
Asked by
Marc Messer
Top achievements
Rank 2
Answers by
Georgi Tunev
Telerik team
Marc Messer
Top achievements
Rank 2
Share this question
or