Copy to clipboard - Chrome/Firefox

Copy to clipboard - Chrome/Firefox

ironcurtainironcurtain Posts: 5Questions: 2Answers: 0
edited April 2016 in Free community support

I've noticed that in Chrome/Firefox copy to clipboard is not working properly in case there are more than about 2000 rows in the table. On the other hand it works fine in IE 11. Also it works in Chrome/Firefox when there are less than 3000 rows in the table.

Answers

  • allanallan Posts: 63,161Questions: 1Answers: 10,406 Site admin

    Do you have a link to a page that demonstrates that issue? I'd like to profile it to see what is happening.

    You note that it doesn't work in Chrome/Firefox with more than 2000 rows, but then state that it works when there are less than 3000 rows. Which is it?

    Thanks,
    Allan

  • ironcurtainironcurtain Posts: 5Questions: 2Answers: 0

    The amount of rows for which it doesn't work is something around 3000. Unfortunately I don't have link. I can send you html code if it will be helpful.
    Aditionaly I noticed that screen is appearing that particural amount of rows were copied to clipboard, but cache holds previous value.

  • allanallan Posts: 63,161Questions: 1Answers: 10,406 Site admin

    If you could use JSFiddle or http://live.datatables.net with your HTML to create a test case that would be a great help. If that isn't possible I'll try to create a test case myself in the next few weeks, but I've got a huge backlog at the moment, so it will likely be a little while before I can.

    Allan

  • TyraelEldruinTyraelEldruin Posts: 5Questions: 1Answers: 0

    I just wanted to say that I am running into the same issue with 2077 rows in Chrome.

    It's not a game changing issue since the excel export still seems to work and that's the main thing we are copying the tables to anyway - but since there's no error message or any indication that it didn't work, it can be a tad confusing when you first run into it.

  • allanallan Posts: 63,161Questions: 1Answers: 10,406 Site admin

    Could your try the nightly version of Buttons please? It now has a fallback if the automatic copy to clipboard fails.

    Allan

  • TyraelEldruinTyraelEldruin Posts: 5Questions: 1Answers: 0
    edited June 2016

    Hey, just wanted to say it looks like it's working now (you have to hit CTRL+C after for it to work), but the PDF button has disappeared.

  • allanallan Posts: 63,161Questions: 1Answers: 10,406 Site admin

    Yes please. Test cases are always welcome.

    Allan

  • TyraelEldruinTyraelEldruin Posts: 5Questions: 1Answers: 0

    Hey Allan, do you know why the PDF button has disappeared with the nightly build?

    It looks like it would make a good replacement, but I don't want to lose the PDF button.

    I'm using:

            dom: "Bfrtip",
            buttons: [
                'copy', 'excel',
                {
                    extend: 'pdfHtml5',
                    orientation: 'landscape',
                }
            ]
    
  • allanallan Posts: 63,161Questions: 1Answers: 10,406 Site admin

    Have you included the pdfmake dependency? The button type should certainly still be there. Can you link to the page showing the issue please?

    Allan

This discussion has been closed.