Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    Error in Export to Excel showcase

    Export to Excel returned -1 instead of date time:

    http://www.smartclient.com/smartclie...dExportBuiltin
    set export format to XLS, Excel 97
    Exported results will contain some sells where neighborhood appears as "##################".
    Selecting the cell shows -1.

    This is true for all Export to Excel samples and not limited to the one URL provided.

    #2
    Hi bkelly,

    are you sure this is not just Excels handling of too narrow columns?
    This is what it looks like in LibreOffice 5.2 of an export of the showcase: Click image for larger version

Name:	Nationhood.PNG
Views:	44
Size:	30.3 KB
ID:	244048

    Best regards
    Blama

    Comment


      #3
      You are half-right. See screenshot. ... This is because Excel handles dates prior to 1900 a little less gracefully. You would need to either use different date-time format or choose an example with dates post 1900. While you are at it PLEASE, PLEASE code review the Export to Excel code. It has real problems with getting the date-time formats right that are very similar to this. They have been there since day 1.

      Click image for larger version

Name:	Capture.PNG
Views:	45
Size:	23.5 KB
ID:	244082

      Search the world's information, including webpages, images, videos and more. Google has many special features to help you find exactly what you're looking for.

      Comment


        #4
        Unfortunately Excel has very serious limitations in its handling of dates and date formatting. We document them here including Excel's inability to handle dates pre-1900.

        If you know of a better approach please do let us know. Keep in mind that one of the key requirements here is that Excel treats date cells as dates - obviously one can provide a pre-1900 date and force Excel to treat it as a String, but this breaks all date-related functionality within Excel.

        Comment


          #5
          Oh and, just to be explicit - if you are aware of an issue with Excel export that is not one of the limitations documented at the URL above, please let us know (as that would be an actual bug).

          Comment

          Working...
          X