Export excel aggregate cell misalignment

7 posts, 1 answers
  1. CORNEL
    CORNEL avatar
    44 posts
    Member since:
    Jan 2012

    Posted 23 Feb 2015 Link to this post

    Hi Guys,

    I have notice when exporting a groupped grid to excel the aggregate cells in excel are offset for some reason to the left and do not match the browser grid aggregate layout and as such the exported file doesnt look as good as it should.
    This can behavior can easily be replicated in the kendo demo page at http://demos.telerik.com/kendo-ui/grid/excel-export

    Cheers!


  2. Atanas Korchev
    Admin
    Atanas Korchev avatar
    8462 posts

    Posted 25 Feb 2015 Link to this post

    Hi Cornel,

    Excel export doesn't currently apply any alignment out of the box. To align the cell text you need to customize the output file and set the hAlign attribute of the required cells.

    Regards,
    Atanas Korchev
    Telerik
     
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
     
  3. CORNEL
    CORNEL avatar
    44 posts
    Member since:
    Jan 2012

    Posted 01 Mar 2015 in reply to Atanas Korchev Link to this post

    Hi Atanas,

    Yes alignment is one thing but im talking about the exported cell offset mismatch. For example in the kendo excel export demo page add an additional groupping by 'Product Name' then under column 'Units On Order' there will be 2 rows of aggregates for Average. All good till here but when exported to excel the Average cell is offseted to the left and appears under 'Unit Price' column instead of 'Units On Order' as it should be per kendo grid.

    Cheers!
  4. Answer
    Atanas Korchev
    Admin
    Atanas Korchev avatar
    8462 posts

    Posted 04 Mar 2015 Link to this post

    Hello Cornel,

    I see what you mean. This actually is a bug rather than misalignment. There is one cell missing during nested grouping. I've landed a fix for this and it will be part of the next internal build.

    Regards,
    Atanas Korchev
    Telerik
     
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
     
  5. CORNEL
    CORNEL avatar
    44 posts
    Member since:
    Jan 2012

    Posted 04 Mar 2015 in reply to Atanas Korchev Link to this post

    Hi Atanas,

    Sounds great and looking forward for the fix! 
    Cheers.
  6. Alan
    Alan avatar
    23 posts
    Member since:
    Apr 2013

    Posted 16 May 2017 in reply to Atanas Korchev Link to this post

    Looking at the demo mentioned in the 1st post (http://demos.telerik.com/kendo-ui/grid/excel-export) it appears that the alignment issue still exists when the export is done as of 5/16/2017. When I do an export from the demo url, the aggregate cell is offset to left while the column cells are aligned to the right.

    See attached.

    Is this still an issue or am I looking at this incorrectly?

  7. Alex Hajigeorgieva
    Admin
    Alex Hajigeorgieva avatar
    1009 posts

    Posted 18 May 2017 Link to this post

    Hello Alan,

    I believe that the missing cell issue has been fixed. I did a test with Kendo UI from 2015 before the fix was pushed by my colleague following the steps Cornel mentions, i.e.

    - add an additional grouping by 'Product Name' then under column 'Units On Order', there will be 2 rows of aggregates for Average.
    - when exported to excel the Average cell is offset to the left and appears under 'Unit Price' column instead of 'Units On Order'



    Result in Excel:



    http://dojo.telerik.com/uMevu

    If you test the same grid with the current version, the output is as expected:




    Here is the demo with the latest version I used:

    http://dojo.telerik.com/aMosES

    For the complete list of cell properties, please check the Kendo UI Workbook namespace:

    http://docs.telerik.com/kendo-ui/api/javascript/ooxml/workbook#configuration-sheets.rows.cells

    Finally, if you are referring to the cell alignment - the default excel behaviour is to align text to the left and numbers to the right based on their type:



    Kind Regards,
    Alex Hajigeorgieva
    Telerik by Progress
    Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Back to Top