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

Grid Height Error: outerHeight returns 1px when grid is on second tab of a TabStrip

1 Answer 81 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Dennis
Top achievements
Rank 1
Dennis asked on 26 Jan 2012, 05:51 AM
When a grid is created on a second tab of a TabStrip.
the header.outerHeight() returns 1px for the line "height -= header.outerHeight();" in function "_scrollable"

see http://jsfiddle.net/ttaylor/9uW3g/ for example

On the "Payment History" tab of the DetailTemplate shows the bug.



1 Answer, 1 is accepted

Sort by
0
Dimo
Telerik team
answered on 26 Jan 2012, 09:54 AM
Hi Dennis,

Generally, Javascript size calculations do not work when the involved elements are placed inside a container with a display:none style, such as the non-active TabStrip tab. As a result, the Grid may not be able to adjust its scrollable layout. Possible workaround include:

1) disable Grid scrolling
2) initialize the Grid after it becomes visible (use the TabStrip select event)
3) adjust the div.k-grid-content height manually in the select event

Regards,
Dimo
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Tags
Grid
Asked by
Dennis
Top achievements
Rank 1
Answers by
Dimo
Telerik team
Share this question
or