issue with jQuery tabs

issue with jQuery tabs

datoismdatoism Posts: 7Questions: 0Answers: 0
edited December 2013 in General
I'm using datatables in tabs.

[code]
$("#tabs").tabs({
"show" : function(event, ui) {
var oTable = $('div.dataTables_scrollBody>table.display',
ui.panel).dataTable();
if (oTable.length > 0) {
oTable.fnAdjustColumnSizing();
}
}
});
[/code]

When the datatable is empty the single row displayed shows a message "No data available in table"
But if i click one tab and then click back the first tab now two rows are displayed with message "No data available in table".
every time i click a tab number of rows increase by one with message "No data available in table".
This is how it looks after few clicks. http://i.imgur.com/BsqsH0U.png

how can I stop this display "No data available in table" only once if no data is there?
This discussion has been closed.