Link to home
Start Free TrialLog in
Avatar of Adrian Cross
Adrian Cross

asked on

Round corners in grid issue.

Hi, I'm trying to add round corners to a gridview using the CSS below. It works fine in IE11 but not in chrome. In Chrome, the border just grows as the page maximizes as the picture below.

At first, it behaved the same in IE but after adding the line  "style="display: table;" worked fine. But as I said, still not good in chrome. Any ideas?

Thanks!

  <div class="rounded-corners" style="display: table;" runat="server">
     <asp:GridView ID="gv" runat="server" AutoGenerateColumns="false" CssClass="mygrid">
....

Open in new window


 .mygrid
{
    border: 1px solid steelblue;
    -moz-border-radius: 5px;
    -webkit-border-radius: 5px;
    border-radius: 6px;
    background-color: White;
    font-family: Verdana;
    font-size: 10pt;
    margin-bottom: 0px;
    
   
}
...

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

Open in new window

User generated image
ASKER CERTIFIED SOLUTION
Avatar of Chinmay Patel
Chinmay Patel
Flag of India image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Adrian Cross
Adrian Cross

ASKER

Many thanks for taking your time putting that together. I just realised I had another div wrapping the border with some bootstrap class which it was causing this. Removing that div, solved the problem.