Grid in Div is not coming properly when we are Hiding and Showing Div.

2 posts, 0 answers
  1. Ashutosh
    Ashutosh avatar
    3 posts
    Member since:
    Nov 2014

    Posted 25 Feb 2015 Link to this post

    In Razor view i have Three divs out of which Two divs are hidden,in hidden div i have declare one div for Grid and i am generating that Grid using html,When i am showing that hidden div then Grid in that div is coming at the left top corner with small size.
    When i am clicking on it, it's showing that Grid properly.
    I am Showing and Hiding these div using "js" file.

    (When i am removing hidden property from that div and loading that div it's not giving me any Problem)i.e
    Working Fine Without Hidden:
    <div id="xyz" >
    <div id="Grid_ID"/>

    Issue  With Hidden Property:
    <div id="xyz" hidden="hidden">
    <div id="Grid_ID"/>

    I have attached the Snap shot,Kindly Find those.
  2. Dimo
    Dimo avatar
    8318 posts

    Posted 27 Feb 2015 Link to this post

    Hello Ashutosh,

    Layout adjustments and size calculations do not work for elements placed inside hidden containers. I suggest you to do the following when showing a <div>, which holds a Grid:

    1. Make sure the Grid wrapper <div> has the expected width and height.

    2. Call the resize(true) method of the respective Grid instance.


    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

  3. UI for ASP.NET AJAX banner
Back to Top