Modal=True Offsetting Window

5 posts, 0 answers
  1. Joe Hakooz
    Joe Hakooz avatar
    65 posts
    Member since:
    Dec 2007

    Posted 27 Mar 2008 Link to this post

    Hi,
    I'm trying to open a RadWindow in the center of the users screen while "disabling" everything behind the window, until the window closes. Setting Modal="true" almost does the trick, but the window is then offset to the right and down. Or it is posistioning itself based on the item clicked. Either way, it's not centered in the browser window.

    Should I be using something other than Modal? I never need more than one window open at a time.
    Also, my RadWindows are different sizes so it seems that hardcoding an offset won't always work.... but I could be wrong.

    Thanks for any suggestions,
    Joe
  2. Georgi Tunev
    Admin
    Georgi Tunev avatar
    7207 posts

    Posted 27 Mar 2008 Link to this post

    Hi Joe Hakooz,

    Are you by any chance using HTML DOCTYPE? This could be a reason for such behavior.
    Basically if you have set Modal to true, the RadWindow should be automatically centered on the page - you can check the behavior of the control in our online demos:
    http://www.telerik.com/DEMOS/ASPNET/Prometheus/Window/Examples/DialogReturnValue/DefaultCS.aspx



    Sincerely yours,
    Georgi Tunev
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Joe Hakooz
    Joe Hakooz avatar
    65 posts
    Member since:
    Dec 2007

    Posted 27 Mar 2008 Link to this post

    Thanks for the reply...

    I removed the HTML DOCTYPE from the page that loads into RadWindow, like your example, but it didn't change anything.

    I noticed that in your example, the width and height are set in the <telerik:radwindow> tag. I send width and height as a JS variable to the RadWindowOpen JS function.

    Could that be the problem?

    Thanks again
  5. Georgi Tunev
    Admin
    Georgi Tunev avatar
    7207 posts

    Posted 27 Mar 2008 Link to this post

    Hello Joe,

    I see that I have missed an important piece of information in my previous reply - I apologize for that. 

    The Prometheus suite of controls, of which RadWindow is a part, is built on top of MS AJAX framework.
    The framework has been developed by Microsoft and is "pushing" for using more standards-compliant web pages - such as the default provided by VS 2005  XHTML 1.0 Transitional.

    The MS AJAX methods that set position and size are not functioning properly in IE with DOCTYPE HTML 4.0.
    We are aware of the problem, and it has been logged as one requiring work around to be developed. In the beginning of the next week, we released a "Futures" version of RadControls Prometheus where we made some changes in the Prometheus core. These changes might improve the situation on your side and we invite you to try the update - it is available in the Downloads section of RadControls Prometheus in your Client.net account.

    Please let us know if the update doesn't help. This problem is logged in our database and we will continue our work in order to provide you with the same experience under DOCTYPE HTML 4.0.



    Regards,
    Georgi Tunev
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  6. Joe Hakooz
    Joe Hakooz avatar
    65 posts
    Member since:
    Dec 2007

    Posted 29 Mar 2008 Link to this post

    Thanks Georgi for your response.

    I was able to find a very simple solution... Since I'm using client-side to launch my window, I just had to add the line...
     oWindow.center()
     ...to the JS call and problem solved.

    Hope this helps,
    Joe
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017