Solved

Gridview not showing right border in IE and Chrome

Posted on 2013-01-03
3
1,380 Views
Last Modified: 2013-01-07
I have a gridview with a nested gridview in side. My nested gridview displays correctly, but my main gridview doesn't display a right border in IE or Chrome. How can I fix this?

The only styles attached to the page currently are the ones in the gridview themselves.

    <asp:GridView ID="GridView1" AllowPaging="True" AutoGenerateColumns="false" DataSourceID="EntityDataSource1"
        DataKeyNames="RequestID" Style="width: 99%;" ShowFooter="true" Font-Size="Small"
        Font-Names="Verdana" runat="server" GridLines="None" OnRowDataBound="GridView1_RowDataBound"
        OnRowCommand="GridView1_RowCommand" OnRowUpdating="GridView1_RowUpdating"
        OnRowDeleting="GridView1_RowDeleting" OnRowDeleted="GridView1_RowDeleted" OnRowUpdated="GridView1_RowUpdated"  BorderStyle="Double" BorderWidth="1px" BorderColor="#000"
        AllowSorting="true">
        <RowStyle BackColor="Gainsboro"  />
        <AlternatingRowStyle BackColor="White"  />
        <HeaderStyle BackColor="#0083C1" ForeColor="White" />
        <FooterStyle BackColor="White" />
        <Columns>
           
            <asp:TemplateField>
                <ItemTemplate>
                    <tr>
                        <td colspan="100%">
                            <div id='div<%# Eval("RequestID") %>' style="display: block; position: relative; left: 15px;
                                overflow: auto; width: 97%">
                                <asp:GridView ID="GridView2" AllowPaging="True" AllowSorting="true" BackColor="White"
                                    Width="100%" Font-Size="X-Small" AutoGenerateColumns="false" Font-Names="Verdana"
                                    runat="server" DataKeyNames="RequestID" OnPageIndexChanging="GridView2_PageIndexChanging"
                                    OnRowUpdating="GridView2_RowUpdating" OnRowCommand="GridView2_RowCommand" OnRowEditing="GridView2_RowEditing"
                                    GridLines="None" OnRowUpdated="GridView2_RowUpdated" OnRowCancelingEdit="GridView2_CancelingEdit"
                                    OnRowDataBound="GridView2_RowDataBound" OnRowDeleting="GridView2_RowDeleting"
                                    OnRowDeleted="GridView2_RowDeleted" OnSorting="GridView2_Sorting" BorderStyle="Double" BorderWidth="1px"
                                    BorderColor="#0083C1">
                                    <RowStyle BackColor="Gainsboro" />
                                    <AlternatingRowStyle BackColor="White" />
                                    <HeaderStyle BackColor="#0083C1" ForeColor="White" />
                                    <FooterStyle BackColor="White" />
                                    <Columns>
                                       
                                    </Columns>
                                </asp:GridView>
                            </div>
                        </td>
                    </tr>
                </ItemTemplate>
            </asp:TemplateField>
        </Columns>
    </asp:GridView>
0
Comment
Question by:NickMalloy
3 Comments
 
LVL 53

Expert Comment

by:COBOLdinosaur
ID: 38741802
Can you post a link to the page?

Cd&
0
 

Author Comment

by:NickMalloy
ID: 38742059
It's not on a public server.
0
 
LVL 23

Accepted Solution

by:
Roopesh Reddy earned 400 total points
ID: 38743032
Hi,

First of all maintain separate CSS styles for styling GridView!

Regarding your problem, check this thread - http://stackoverflow.com/questions/9422326/gridview-lines-not-showing-up-in-ie

Hope it helps u...
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

When writing CSS, there are a few simple rules that will make your life easier.    1. Using ‘* {box-sizing:border-box;}’. Using this will wrap all your elements in a nice little compact box-model that will give you the width you want, like so... …
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
In this tutorial viewers will learn how to define a gradient in CSS. Create a new HTML document with an internal stylesheet.: Create a div in CSS and name it Gradient. Define the background as "linear-gradient(to right, #ee3668, black)". Ensure you …
In this Micro Tutorial viewers will learn how to create navigation buttons that change on rollover, using CSS (Continuation of the CSS Image Sprite tutorial) Create a parent ID for all the list items       - Specify position: absolute and display: block…

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now