DhtmlxDataView attach to DhtmlxLayout

I want to attach a DhtmlxDataView to DhtmlxLayout. I code as this:

var dhxLayout; var data; function doOnLoad() { dhxLayout = new dhtmlXLayoutObject("parent", "3U"); data = dhxLayout.cells("b").attachDataView(); data = new dhtmlXDataView({ container: "data_container", height: "auto", }); data.define("type", "ficon"); data.customize({ icons_src_dir: "../common/images" }); data.load("biolock/xml/files_ext.xml"); }
When I test, I get a problem that is “TypeError: b is undefined(…var b=dhtmlx.copy._function;b.prototype=a;return new b};dhtmlx.copy._function=fu…)”.
What should I do for it?

To avoid such issue you need the next:
config = {…};

data = layout.cells(“a”).attachDataView(config);