I get the error: Uncaught TypeError: Object # has no method ‘splitAt’ i console.
This is my code:
initMyGrid();
function initMyGrid() {
if ($("#gridMy").length > 0) {
gridS = new dhtmlXGridObject('gridMy');
gridS.setImagePath(window.dhx_globalImgPath);
gridS.enableColumnMove(true);
gridS.enableAutoWidth(true);
gridS.enableMultiselect(true);
gridS.setSkin("light");
gridS.setInitWidthsP("150, 150, 150, 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, 50");
gridS.enableSmartRendering(true);
gridS.isLoaded = false;
}
}
$(function () {
loadMyGrid();
});
function loadMyGrid() {
$("#gridMy").empty();
initMyGrid();
gridS.isLoaded = true;
gridS.clearAll();
$.ajax({
type: "GET",
async: true,
url: "/MyController/ListData",
data: {
//
},
success: function (data) {
if (data.widths != undefined) { gridS.setInitWidths(data.widths); }
gridS.init();
gridS.splitAt(2);
gridS.loadXMLString(data.data, function () { });
}
});
}
I want it to behave like this:
dhtmlx.com/docs/products/dht … split.html
and instead I get error.