Set multiple behaviors for Rad Window

4 posts, 0 answers
  1. Acadia
    Acadia avatar
    203 posts
    Member since:
    May 2005

    Posted 22 Dec 2008 Link to this post

    How do you programatically set multiple behaviors for a rad window.  I can get it to accept a sibngle behavior such as close or move but how do you tell it to have both Close and Move.

    Thanks
  2. Stuart Hemming
    Stuart Hemming avatar
    1622 posts
    Member since:
    Jul 2004

    Posted 22 Dec 2008 Link to this post

    Below is a sample from one of my apps. It sets the behaviours for all of the windows invoked by this page. You can do this on a window-by-window basis by setting the Window property rather than that of the WindowManager.
    WindowManager.Behaviors = WindowBehaviors.Close | WindowBehaviors.Move | WindowBehaviors.Resize | WindowBehaviors.Maximize; 

    You can do this 'cos the WindowsBehaviours enum is defined using the [Flags] attribute. See this MSDN article for more details about enums and the [Flags] attribute.

    Hope this helps.

    --
    Stuart
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Ashwin
    Ashwin avatar
    6 posts
    Member since:
    Apr 2013

    Posted 26 Apr 2013 Link to this post

    Hello There, 

    When I set behaviors as "Move" for Rad WIndow, it moves the window, but we can move it to any location even our screen ends still you can move it. How to restrict user for not moving the window out of parent screen layout ?
  5. Shinu
    Shinu avatar
    17764 posts
    Member since:
    Mar 2007

    Posted 26 Apr 2013 Link to this post

    Hi,

    You cannot prevent the user from dragging an object outside of the original viewport area. You can set the KeepInScreenBounds property of the RadWindow to true so that window will stay in the visible viewport of the browser window.

    Thanks,
    Shinu
Back to Top