pqgrid.min.js:11 Uncaught TypeError: Cannot read property 'wdCenter' of undefined
at pq.cRenderBody.refreshColumnWidths (pqgrid.min.js:11)
at pq.cRenderBody.init (pqgrid.min.js:17)
at t.paramquery.cRefresh.refresh (pqgrid.min.js:12)
at pqgrid.min.js:12
at pqgrid.min.js:12
function addtab(){
var now = new Date();
var y = now.getFullYear();
var m = now.getMonth() + 1;
var d = now.getDate();
var w = now.getDay();
var h = now.getHours();
var mi = now.getMinutes();
var s = now.getSeconds();
var a = Math.floor( Math.random() * 11 ) ;
var tabname = w + "" + h + "" + mi + "" + s + "" + a;
$( "<li class='tab" + tabname + "'><a href='#tabs-" + tabname + "'>New Tab" + tabname + "</a></li>" )
.appendTo( "#tabs .ui-tabs-nav" );
$( "<div id='tabs-" + tabname + "'><div id='grid_editing-" + tabname + "' style='margin: auto;'></div></div>" )
.appendTo( "#tabs" );
$( "#tabs" ).tabs( "refresh" );
pq.grid( "#grid_editing-" + tabname, []);
}
$(function () {
$("#tabs").tabs();
setTimeout( function(){
addtab();
}, 2000 );
});
<div id="tabs">
<ul>
<li><a href="#tabs-1">tab1</a></li>
</ul>
<div id="tabs-1"></div>
</div>