Attach the dropdown to the input element while scrolling within a scrollable container

Thread is closed for posting
1 posts, 0 answers
  1. 63F75A2C-1F16-4AED-AFE8-B1BBD57646AD
    63F75A2C-1F16-4AED-AFE8-B1BBD57646AD avatar
    1572 posts
    Member since:
    Oct 2004

    Posted 25 Oct 2013 Link to this post

    Requirements

    RadControls version 2013.3.1015
    .NET version 4.0
    Visual Studio version 2012
    programming language C#
    browser support

    all browsers supported by RadControls


    PROJECT DESCRIPTION

    This project shows how you can overcome the following issue with our RadComboBox control : when the RadComboBox control is placed within a scrollable container and user tries to scroll with the mouse and the drop down is opened, the drop down element "freezes" and stays on same spot on the screen while all other elements scroll with the page.

    * Please note that for sample purposes the scrollable container has fixed height and padding value. The scenario is a bit extended  so the drop down is closed either when the RadComboBox reaches the upper or bottom part of the container. This functionality is achieved with some client-side calculations explained with few comments in the code. Please NOTE that those calculations would work as expected only if the scrollable container has position relative.
    <style type="text/css">
            .scrollabeContainer {
               ......
                position: relative;
               ....
            }
        </style>

Back to Top

This Code Library is part of the product documentation and subject to the respective product license agreement.