This is a migrated thread and some comments may be shown as answers.

grid lines are not displaying in exported data

1 Answer 321 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Ram
Top achievements
Rank 1
Ram asked on 30 Mar 2009, 12:18 PM
Hi,

After exporting grid data to pdf or excel, When open those files I am unable to see the grid lines in theme (grid lines are missing)

my code is as follows:

<radG:RadGrid ID="dgReport" runat="server" Skin="Default" EnableEmbeddedSkins="false" >
                                <ExportSettings OpenInNewWindow="True" IgnorePaging="True">
                                    <Pdf Author="Anonymous" Title="RadGrid export" Subject="RadGrid Export" Keywords="None"
                                        AllowCopy="True" AllowModify="True" PageTopMargin="1in" PageBottomMargin="1in"
                                        PageLeftMargin="0.2in" PageRightMargin="0.2in"></Pdf>
                                </ExportSettings>
                                <MasterTableView  HeaderStyle-Wrap="false" ItemStyle-Wrap="false">
                                    <ExpandCollapseColumn>
                                        <HeaderStyle Width="20px" />
                                    </ExpandCollapseColumn>
                                    <RowIndicatorColumn>
                                        <HeaderStyle Width="20px" />
                                    </RowIndicatorColumn>
                                  
                                </MasterTableView>
                                <FilterMenu EnableTheming="True">
                                    <CollapseAnimation Duration="200" Type="OutQuint" />
                                </FilterMenu>
            </radG:RadGrid>

code behind:

bool isPdfExport = false;
protected void btnExportToPdf_Click(object sender, EventArgs e)
        {
          
                isPdfExport = true;
                 dgReport.ExportSettings.ExportOnlyData = false;
                dgReport.ExportSettings.Pdf.PageWidth = 2000;
                dgDReport.MasterTableView.ExportToPdf();
         }

What is the reason for this ?

Thanks,

1 Answer, 1 is accepted

Sort by
0
Accepted
Shinu
Top achievements
Rank 2
answered on 31 Mar 2009, 06:23 AM
Hi Ram,

In the above given aspx you are not setting any GridLines property. Try setting the GridLines property to Both and see whether the Grid lines are getting exported.

ASPX:

<
rad:RadGrid ID="RadGrid1" DataSourceID="SqlDataSource1" runat="server"  GridLines="Both" Skin="Default"   > 


Thanks
Shinu
Tags
Grid
Asked by
Ram
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
Share this question
or