Datatable Errors with Multiple tables on a form


I am having issues when I have multiple datatables on a form. I would like to use about 4 datatables.

There seems to be some timing conflict with the NSB code when I go beyond 3.

It gives the following exception. (Jquery.datatable failed into insertBefore on Node…)


The conflicting code looks like it comes from NSB when it tries to do a build() on the tables from a setTimeout event.

Is there anyway that this can be turned off or is there something else I need to look at?

Many Thanks

I’ve used multiple datatables on a form without problems, so that’s not the direct issue. I haven’t seen your problem before.

DataTables isn’t our product, though it works well with AppStudio. We’re not experts in it, so we can’t tell you how to fix it. Keep digging - it’s a solid library and there’s always a good reason for things happening the way they do.

Just a question, why do you initialize the data tables in the NSB “Load” code?

  data = [['Tiger Nixon', 'System Architect', '$320,800'],['Garrett Winters', 'Accountant', '$170,750']];
  columns = [{title:'Name'}, {title:'Position'}, {title:'Salary'}], 'DataTable_bs4');
     data: data,
     info: true,
     lengthChange: true,
     lengthMenu: [5, 10, 25],
     ordering: true,
     paging: false,
     searching: true,
     columns: columns

This is the build() that is causing my issue.



Just a guess - is being called with a half second delay. That may be too soon.

By putting it in the load code, it should wait until the table is completely loaded before trying to insert values into it.

Hi George

That code is part of the NSB generated code. (index.html)

I don’t have control over the delay do I?


Best Regards



You’re right - we’d better have a look at that. Thank you!