开发者

change Width Gridview While containing 100 words;

change Width Gridview While containing 100 words;

gridInbox.Rows[i].Cells[4].Wrap = false;
gridInb开发者_如何学运维ox.Rows[i].Cells[4].Width  = 10;

does not work;


Can you add more details as to exactly what you are doing and what the desired outcome is?

Assuming you are trying to make the cells not get any bigger regardless of the amount of text? If so you can enforce a style of the produced tables by setting the css:

gridviewStyle
{
    table-layout:fixed;
}

gridviewColumnStyle
{
    text-overflow:ellipsis;
    overflow:hidden;
    white-space:nowrap;
    width: 10;
} 

Set your GridView and the columns you want to enforce to use the above css.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜