开发者

Auto stretching of adjacent column size when the current column has a lot of elements in a gridview

I have two columns in a table in ASP.NET page. In the first column I have a Grid View that gets populated from the database using the SQLDATASOURCE.

In the second column I have certain textboxes and checkboxes and buttons.

When I run the page in a browser, the data gets populated in the gridview which actually disturbs the alignment of the adjacent column that contains the textboxes and the checkboxes.

These textboxes and checkboxes that are supposed to be visible at the top of the column are now visible at the center becaus开发者_如何学编程e the gridview data populated disturbs it.

Please help with this as I want these textboxes and checkboxes in the second column to be visible at the top of the column.


You need to set the vertical alignment of your second table cell:

<td style="vertical-align:top">xx</td>

The default value is "middle" which is why your content gets pushed to the middle as the vertical height of the table cell gets taller than your content.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜