javascript error when using aoColumns

javascript error when using aoColumns

snarf2larfsnarf2larf Posts: 64Questions: 0Answers: 0
edited February 2013 in DataTables 1.9
I'm using datatables with bootstrap and when I try to add any settings through aoColumns I receive the error in Chrome "Uncaught TypeError: Object [object Object] has no method 'charCodeAt'".

This only pops up when I add settings to aoColumns, if I remove them everything functions normally.

[code]
"aoColumns": [
{ "bVisible": 0 }, /* ID column */
null,
null,
null,
null,
null,
null,
null,
null,
null,
null
],
[/code]

I'm using the latest version of datatables 1.9.4. Here is the debug output: http://debug.datatables.net/usuded

The error is on line 3879 in function _fnStringToCss called by _fnCalculateColumnWidths called by _fnInitialise

[code]
var c = s.charCodeAt( s.length-1 );
[/code]

Any ideas?

Replies

  • allanallan Posts: 63,498Questions: 1Answers: 10,471 Site admin
    Hi,

    Are you using jQuery UI and if so, what are you using? We've found in the past that some older versions of jQuery UI can do slightly odd things with the width calculation (it alters the jQuery sizing code in some manner), resulting in an error just like this.

    Regards,
    Allan
  • snarf2larfsnarf2larf Posts: 64Questions: 0Answers: 0
    edited February 2013
    I'm using 1.8.21. I see removing it resolves the issue so I'll try using an updated version.

    Thanks!
This discussion has been closed.