Dynamic Smart Rendering on a Grid doesen’t seem to work if one of the columns is set to “tree” (ver 2.6 Pro). The Grid will only display the first “x” results based on the number of rows set to render.
Are there any plans to release a fix to allow a Tree Grid to use Smart Rendering?
When I enable smart rendering for the grid the scrollbar doesen’t go down to the end of the table (it seems to stop at the first x records based on what the fetch size is set to).
The example above seems to show smart rendering for loading nodes only.
The following post seems to imply that smart rendering isn’t supported by the grid if using a tree column (the person has the exact same issue as I do).
dhtmlxTreeGrid does support static Smart Rendering mode. You can see example here dhtmlx.com/docs/products/dht … _srnd.html
In such mode all rows are loaded at once, but only those are rendered which should be displayed to the user.
dhtmlxTreeGrid does not support dynamic loading of one level. One level of rows in TreeGrid should be loaded at once. You can use dynamic loading of sub items only.
Thanks for the extension, the Dynamic smart rendering now works fine with Tree Grid.
However in this version I cannot correct the bug with IE 8 when smart rendering is used. In the past I had to add the following code to dhtmlxgrid.js to correct this (I found this in another post) but it doesen’t seem to work if I add it to this version. Can you tell me how I can get it working? Out of interest, I noticed that I still had to add this code when I upgraded to v2.6 so I’m wondering why it wasn’t included even in the official release?
dhtmlXGridObject.prototype.render_dataset = function(min, max) {
//normal mode - render all
//var p=this.obj.parentNode;
//p.removeChild(this.obj,true)
if (this._srnd) {
if (this._fillers)
return this._update_srnd_view();
max = Math.min((this._get_view_size() + (this._srnd_pr || 0)), this.rowsBuffer.length);
}
if (this.pagingOn) {
min = Math.max((min || 0), (this.currentPage - 1) * this.rowsBufferOutSize);
max = Math.min(this.currentPage * this.rowsBufferOutSize, this.rowsBuffer.length)
} else {
min = min || 0;
max = max || this.rowsBuffer.length;
}
for (var i = min; i < max; i++) {
var r = this.render_row(i)
if (r == -1) {
if (this.xmlFileUrl) {
if (this.callEvent("onDynXLS", [i, (this._dpref ? this._dpref : (max - i))]))
this.load(this.xmlFileUrl + getUrlSymbol(this.xmlFileUrl) + "posStart=" + i + "&count=" + (this._dpref ? this._dpref : (max - i)), this._data_type);
}
max = i;
break;
}
if (!r.parentNode || !r.parentNode.tagName) {
this._insertRowAt(r, i);
if (r._attrs["selected"] || r._attrs["select"]) {
this.selectRow(r, r._attrs["call"] ? true : false, true);
r._attrs["selected"] = r._attrs["select"] = null;
}
}
if (this._ads_count && i - min == this._ads_count) {
var that = this;
this._context_parsing = this._context_parsing || this._parsing;
return this._contextCallTimer = window.setTimeout(function() {
that._contextCallTimer = null;
that.render_dataset(i, max);
if (!that._contextCallTimer) {
if (that._context_parsing)
that.callEvent("onXLE", [])
else
that._fixAlterCss();
that.callEvent("onDistributedEnd", []);
that._context_parsing = false;
}
}, this._ads_time)
}
}
if (this._srnd && !this._fillers) {
var fh = this.rowsBuffer.length - max;
this._fillers = [];
while (fh > 0) {
this._fillers.push(this._add_filler(max, Math.min(fh, 50000)));
max += 50000;
fh -= 50000;
}
}
//p.appendChild(this.obj)
this.setSizes();
};
Is the dynamic smart rendering for TreeGrid publicly available or is it provided on a per-request basis. It is currently not functioning on Pro v.3.0 build 110707.
Unfortunately the dynamic smart rendering functionality wasn’t released officially. Also it’s not clear if it will be available officially in the future.
You may open ticket at http://support.dhtmlx.com/ and we shall send you this extension.
Get a guaranteed answer from DHTMLX technical support team
under the most suitable support plan