如何在我的.NET code圆角添加到一个GridView表? [英] How do I add rounded corners to a GridView table in my .net code?

查看:148
本文介绍了如何在我的.NET code圆角添加到一个GridView表?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试着加入WebKit的边界半径/ MOZ边界半径/圆角半径,以两个CSS定义和.NET的定义,但无济于事。救命啊!

I've tried adding webkit border radius / moz border radius / border radius to both the css definition and the .net definition, but to no avail. Help!

<tr>
    <td width="60%" align="center">
        <asp:GridView ID="GridView_VE" runat="server" CssClass="table1" HorizontalAlign="Center" Width="80%"   
        OnPageIndexChanging="GridView_VE_PageIndexChanging" Font-Names="Century Gothic" Font-Size="Large" Height="100%"
        AllowPaging="True" PageSize="4" RowStyle-Height="30px" -webkit-border-radius= "10px" -moz-border-radius="10px"
        border-radius="10px" border="2px" border-color="Black">
            <Columns>
            ...
            </Columns>
            <PagerStyle Height="20px" />
            <RowStyle Wrap="True" />
         </asp:GridView>
    </td>
</tr>

我已经试过落实角落的TD,TR和表了。但同样,失败。

I've tried implementing the corners to the td , tr and table too. But again, fail.

推荐答案

裹在&LT; ASP:GridView的&GT; 在一个div,然后将圆角上DIV 。

Wrap the <asp:GridView> in a div and then place the rounded corners on that div.

<div class="rounded-corners">
    <asp:GridView>....</asp:GridView>
</div>

和CSS的

.rounded-corners {
  border: 1px solid black;
  -webkit-border-radius: 8px;
  -moz-border-radius: 8px;
  border-radius: 8px;
  overflow: hidden;
}

这篇关于如何在我的.NET code圆角添加到一个GridView表?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆