Tables and Export To Excel

4 posts, 0 answers
  1. Peter
    Peter avatar
    6 posts
    Member since:
    Mar 2012

    Posted 09 Jul 2012 Link to this post

    Hi;

    I have a report that uses a table item. When this report is exported to excel some of the table cells span across multiple cells in Excel. I would like to know how to avoid this and make sure that each cell in the Report Table item control gets converted to only 1 worksheet cell in Excel.

    Update:
        I have a header on the report and a section below the table that displays a legend. When I do not display these 2 sections the table does not export with merged cells to Excel. So is there an option that can specify that the table is to exported exaclty as defined to Excel?


    Ok - I read more about export operations and it makes sense that merge cells is possible if different content is being used on the report. Then the export functionality has to determine the best mapping to Excel which may require cells to be merged (I don't know if a worksheet can have different sections that are seperated - i.e do not use the same merges on the same fields). If someone has a good technique to try and optimize this then I would like to hear about it.

    Peter
  2. Elian
    Admin
    Elian avatar
    435 posts

    Posted 12 Jul 2012 Link to this post

    Hello Peter,

    In order to avoid the merging, all report's content should be aligned in one (imaginary) grid. Meaning that if you continue the lines of the table, all other object should be be aligned according to these lines. See the attached screenshot for a graphic example - the same thing applies to vertical merging. More information is available in the Design Considerations for Excel Rendering help article.
     
    Kind regards,
    Elian
    the Telerik team

    BLOGGERS WANTED! Write a review about Telerik Reporting or the new Report Designer, post it on your blog and get a complimentary license for Telerik Reporting. We’ll even promote your blog and help bring you a few fresh readers. Yes, it’s that simple. And it’s free. Get started today >

  3. bijay
    bijay avatar
    1 posts
    Member since:
    Feb 2019

    Posted 19 Jun Link to this post

    Hi 

    As i am New to telerik i am unable Export to Excel  manually Telerik Reporting Table,i need souce code(mvc) step by step for that,

    can you please help me

  4. Neli
    Admin
    Neli avatar
    80 posts

    Posted 24 Jun Link to this post

    Hello bijay,

    You may use the ReportProcessor class to export the report and return it as a file attachment. I suggest you to take a look at Print a report directly at client-side without displaying it in a Viewer KB article where the required steps to print a report directly at  the client-side without displaying it in the viewer are listed. In the attached project you can see this approach demonstrated for Excel exporting. In the sample I have excluded the special JavaScript for invoking the print dialog from the KB.

    Note that you cannot export a singe Data Item - it should be included in a Report.

    You might also find Exporting a report to PDF programmatically KB article helpful.
    Our MVC demo which can be found at C:\Program Files (x86)\Progress\Telerik Reporting[Version]\Examples\CSharp\MvcDemo may also be useful.

    Regards,
    Neli
    Progress Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Back to Top