2012-06-21 51 views
3

有沒有人知道改變Telerik Extensions for MVC Grid的高度的方法?除了重寫風格手動使用更改TelerikMVC Grid Control的高度

div#MyGrid .t-grid-content { 
    height: 100px !important; 
} 

我想在網格本身,而不是在樣式表控制。 Telerik的樣品和文檔沒有提到它,它似乎是not supported

有沒有人遇到(和解決)相同的問題?

回答

6

您可以使用Scrollable方法控制網格的高度。

使用代表像素的INT32:

.Scrollable(scrolling => scrolling.Height(500)) 

使用字符串:

.Scrolling(scrolling => scrolling.Height("20em")) 
+0

工作的魅力!謝謝! – pollirrata