DataTables Custom Button
DataTables Custom Button
zgoforth
Posts: 493Questions: 98Answers: 2
Hello, so I have been doing some research on DataTables buttons (with bootstrap), and wasn't able to come across anything that stood out to me/was what I was looking for. Is it possible to create a custom button on a DataTable (within a button collection) that will download a file from a SharePoint folder? For example a userguide?
This question has an accepted answers - jump to answer
This discussion has been closed.
Answers
This example shows how to use custom buttons with a button collection.
Kevin
@kthorngren Hey, I tried to add to my button collection but it gives me an error and doesn't work like intended.. Here is JSFiddle https://jsfiddle.net/opcmb86w/ . Ever since I added the new modal with the PDF location and the new button, my table doesn't appear anymore neither does the button collection
You have a syntax error:
Click on the line in the error and it shows this code:
You are missing the closing
}
for line 1. It should go on line 6.Kevin
@kthorngren I already tried that, and it still doesn't work... tells me
Uncaught SyntaxError: Unexpected token '{'
at line 1I placed the
}
in the spot I mentioned and didn't complain about syntax errors.Kevin
@kthorngren Hm. so did I in my code.. and it gave me the same issue.. Could it be something with the HTML modal initalization
If you are getting this in your code (not the example) then you have another issue in your Javascript code that needs fixed. You are missing or have an extra symbol somewhere.
Kevin
This is not a DataTables problem.
Run your code through a Javascript validator.