DataTables pdfmake.min.js

DataTables pdfmake.min.js

tinac99tinac99 Posts: 7Questions: 6Answers: 0

Hi,

I am using .net and have this code in my layout page:

Layout page

    <link href="~/Scripts/Jquery/jquery-ui-1.12.1/jquery-ui.css" rel="stylesheet" type="text/css" />
    <script src="~/Scripts/jquery-3.3.1.js"></script>

    <script src="~/Scripts/Jquery/jquery-ui-1.12.1/jquery-ui.js"></script>

    <link rel="stylesheet" href="~/lib/bootstrap/dist/css/bootstrap.css" />
    <script src="~/lib/bootstrap/dist/js/bootstrap.js"></script>

    <link rel="stylesheet" type="text/css" href="~/Scripts/DataTables/datatables.min.css" />
    <link rel="stylesheet" type="text/css" href="~/Scripts/DataTables/buttons.dataTables.min.css" />

    <script type="text/javascript" src="~/Scripts/DataTables/datatables.min.js"></script>
    <script type="text/javascript" src="~/Scripts/DataTables/dataTables.buttons.min.js"></script>
    <script type="text/javascript" src="~/Scripts/DataTables/buttons.flash.min.js"></script>
    <script type="text/javascript" src="~/Scripts/DataTables/pdfmake.min.js"></script>

    <script type="text/javascript" src="~/Scripts/DataTables/vfs_fonts.js"></script>
    <script type="text/javascript" src="~/Scripts/DataTables/buttons.html5.min.js"></script>
    <script type="text/javascript" src="~/Scripts/DataTables/buttons.print.min.js"></script>

My DataTable implementation is simply:

@if ((Model != null) && (Model.result != null)) { @foreach (var item in Model.result) { } }
Receive Date PO/RMS Material Description Quantity Received Quantity Inventory Bin
@Html.ActionLink(@item.ReceiveDate.ToString("MM/dd/yyyy"), "CreateAndDisplayDate", new { adtReceiveDate = @item.ReceiveDate }) @item.PORMS @item.MaterialDescription @String.Format("{0:#,###0}", item.QuantityReceive) @String.Format("{0:#,###0}", item.QuantityAvailable) @item.Bin
$(document).ready(function() { $("#ReceiveInv").DataTable(); });

The DataTable works but, there's always the error below which shows up in the debugger. I am thinking it is a contributor in the slowness of the application.

0x800a139e - JavaScript runtime error: Exception thrown and not caught
Exception was thrown at line 14, column 159223 in https://localhost:44339/Scripts/DataTables/pdfmake.min.js
0x800a138f - JavaScript runtime error: Unable to get property '1' of undefined or null reference

I appreciate your input.

Thanks,

tinac99

Answers

  • colincolin Posts: 15,240Questions: 1Answers: 2,599

    Hi @tinac99 ,

    We're happy to take a look, but as per the forum rules, please link to a test case - a test case that replicates the issue will ensure you'll get a quick and accurate response. Information on how to create a test case (if you aren't able to link to the page you are working on) is available here.

    Cheers,

    Colin

This discussion has been closed.