export to excel not working in IE11

export to excel not working in IE11

UleeUlee Posts: 5Questions: 1Answers: 1
edited September 2016 in Free community support

I have a simple datatables implementation:

$(tableID).DataTable( {
dom: 'Bfrtip',
buttons: [
'excel','copy' ],
});

and it works in Chrome and in FF.
I have both flash and html5 buttons linked in.

When I try to download from IE got following message:

Do you want to open or save .xlsx[1] (11,3KB) from 'sitename.aspx'?

When I try to save I got:
.xlsx[1] couldn't be downloaded.
In the destination save folder I got this file: .xlsx[5].g90qjkz.partial

Copy button works fine.(asks for permissions first)
Flash is enabled in IE.
I couldn't recreate this in fidle. http://live.datatables.net/degacimo/1/
Any idea what could be cousing the issue?

This question has an accepted answers - jump to answer

Answers

  • allanallan Posts: 43,525Questions: 1Answers: 5,695 Site admin

    Does this example work for you in IE11 or not? It does appear to for me.

    Allan

  • UleeUlee Posts: 5Questions: 1Answers: 1

    Yes it does,
    when I change code to:
    buttons: [
    'excelHtml5']

    or

    buttons: [
    'flashexcel'
    ]

    got the same error as described (couldn't download file)

  • allanallan Posts: 43,525Questions: 1Answers: 5,695 Site admin

    flashexcel

    There is no such button - there is an excelFlash button, which should work.

    Can you link to a running page showing the issue please?

    Allan

  • UleeUlee Posts: 5Questions: 1Answers: 1
    edited September 2016

    sorry for typo,it is excelFlash button I am using.

    When I go to developer tools and change document mode to 9 (from 10 default) it is not showing Excel button at all.

    I am not able to recreate the issue in fiddle. Page is behind the firewall ..

  • allanallan Posts: 43,525Questions: 1Answers: 5,695 Site admin

    If the example on this site works, I'm not sure that there is much help I can offer without a test case showing the problem I'm afraid.

    Allan

  • UleeUlee Posts: 5Questions: 1Answers: 1

    Thx for trying Allan :)

  • UleeUlee Posts: 5Questions: 1Answers: 1
    Answer ✓

    Fixed the issue by setting up the file name:
    dom: 'Bfrtip',
    buttons: [
    {
    extend: 'excelHtml5',
    title: 'Data export'
    }]

  • kirankkrkirankkr Posts: 1Questions: 0Answers: 0
    edited October 2016

    Hello,

    I have the similar issue I am using the data table as follows, I added title too still not working. I can't see any button in the IE 11. This is working in chrome.

    $(tableID).dataTable({         
              "stateSave": false,
              "scrollY":  "300px",       
              "scrollX": true ,    
              "scrollCollapse": true,
            "paging": true,            
            "ordering": true,
            "order": [[ 3, "desc" ]]
            "info": false,
            "pageLength": 100,
            "searching": true,
            "dom": 'Blfrtip',
            buttons: [
            {extend: 'excel',
             footer: 'true',
            text: 'Export',
            title:'Data Export'  }]  
         });
    
  • allanallan Posts: 43,525Questions: 1Answers: 5,695 Site admin

    @kirankkr - We'd need a lnik to a page showing the issue please.

    Allan

  • mustardman23mustardman23 Posts: 1Questions: 0Answers: 0

    I think the problem is related to the page title. I was opening the project in a development environment and didn't think to put the title as it was not important really. However, IE may require the title for the page before the dowload can be started.

  • allanallan Posts: 43,525Questions: 1Answers: 5,695 Site admin

    @mustardman23 - Thanks for posting this! I'm doing some work for the next release of Buttons just now and I'll make sure I put in a workaround for that.

    Allan

  • allanallan Posts: 43,525Questions: 1Answers: 5,695 Site admin

    This has been fixed now (finally!) and will be in Buttons 1.5.0.

    Allan

Sign In or Register to comment.