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

[Solved] UseclassicWindows unable to center RadWindow

2 Answers 140 Views
Window
This is a migrated thread and some comments may be shown as answers.
Yann
Top achievements
Rank 1
Yann asked on 29 Apr 2009, 10:16 AM
Hello,

when I use RadWindowManager with UseClassicWindows set to true, Im' not able to center my radWindow, and my RadWindow doesn't appear to be modal.
I've tried to move my window to 400,400 to make a test, but it doesn't work.
Here is my code :

        function showWindow()    
        {    
            var ownd = radopen("splash.html""splash");    
            ownd.Show();    
            ownd.MoveTo(400,400);  
 
            /*var oManager = GetRadWindowManager();
            var oWnd = oManager.GetWindowByName("Splash");
            oWnd.Show();
            SizeToFit();*/ 
        }  
 

And my html tags :

        <form id="Form1" method="post" runat="server">  
        <radw:RadWindowManager ID="Singleton" runat="server" Visible="true" VisibleStatusbar="false"    
        Top="400" Left="400" DestroyOnClose="true" ShowContentDuringLoad="false"    
        Behaviors="Close,Move">    
        </radw:RadWindowManager>   
            <asp:PlaceHolder id="Contenu" Runat="server"></asp:PlaceHolder> 
        </form> 
 

In my code in page_load I've set the properties of RAdWindowManager :

        Singleton.UseClassicWindows = True 
        Singleton.VisibleStatusbar = False 
        Singleton.VisibleTitlebar = False 
        Singleton.Modal = True 
 

Thanks for your help
Yann

2 Answers, 1 is accepted

Sort by
0
Georgi Tunev
Telerik team
answered on 29 Apr 2009, 11:08 AM
Hi Yann,

When you set UseClassicWindows=true, you will be using the standard browser's popups, not the RadWindow's one. To work with them, you need to use the appropriate Javascript methods like for example window.close();. To be able to use RadWindow's rich client-side API, you need to work with the RadWindow object, e.g. UseClassicWindows=false.

More information on browser's popup and how to work with it is available on the Net.



Greetings,
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
Princy
Top achievements
Rank 2
answered on 29 Apr 2009, 11:17 AM
Hi Yann,

You can try following client side code for showing the RadWindow in the center of page if you are using UseClassicWindows to True.

JavaScript:
 
<script type="text/javascript">  
function showWindow()  
{      
   var ownd = window.radopen('Window1.aspx''Win1');    
   var w = ownd.ClassicWindow;           
   w.moveTo(400, 400);  
}  
</script> 

Thanks,
Princy.
Tags
Window
Asked by
Yann
Top achievements
Rank 1
Answers by
Georgi Tunev
Telerik team
Princy
Top achievements
Rank 2
Share this question
or