Hi Sharath,
You can obtain the div element containing the control using:
NClientNode.GetFromId("Chart1").HtmlElement;
(Chart1 is the state id of the control - check out custom requests example). Later you can use this element to position a loader gif image at the center. This is how its done in the control when it shows loader images in tiled rendering:
// shows the loader
NTiledImageCell.prototype.ShowLoader = function () {
var loaderUrl = this.Parent.LoaderUrl;
if (this.LoaderDiv != null || loaderUrl == null || loaderUrl.length == 0) {
return;
}
var jHtmlElement = $(this.HtmlElement);
var rect = this.GetRect();
var loaderDiv = document.createElement("div");
this.LoaderDiv = loaderDiv;
var jLoaderDiv = $(loaderDiv);
jLoaderDiv.css("position", "absolute");
jLoaderDiv.css("left", rect.X + "px");
jLoaderDiv.css("top", rect.Y + "px");
jLoaderDiv.css("width", rect.Width + "px");
jLoaderDiv.css("height", rect.Height + "px");
jLoaderDiv.css("margin", 0);
jLoaderDiv.css("padding", 0);
jLoaderDiv.css("border-width", 0);
jLoaderDiv.css("background-repeat", "no-repeat");
jLoaderDiv.css("background-image", "url('" + this.Parent.LoaderUrl + "')");
jLoaderDiv.css("background-position", "center");
$(this.Parent.HtmlElement).append(loaderDiv);
}
// hides the loader
NTiledImageCell.prototype.HideLoader = function () {
if (this.LoaderDiv != null) {
$(this.LoaderDiv).remove();
this.LoaderDiv = null;
}
}
Best Regards,
Nevron Support Team