Hi Guys,
I have an issue with Load on demand. I have two projects. One is Web Project and one Library project where i'm adding WebDataTree (and use it as dll refernece i Web Project).
Definition on data tree is:
InnerTree = New WebDataTree()
InnerTree.ID = Me.UniqueID
InnerTree.DragDropSettings.DragDropMode = DragDropMode.Copy
InnerTree.DragDropSettings.EnableDragDrop = True
InnerTree.DragDropSettings.AllowDrop = False
InnerTree.ClientEvents.DragEnter = "InnerTree_DragEnter"
InnerTree.ClientEvents.NodeDropping = "InnerTree_DragEnter"
InnerTree.EnableAjax = True
InnerTree.EnableAjaxViewState = True
InnerTree.EnableViewState = True
InnerTree.InitialExpandDepth = 1
InnerTree.InitialDataBindDepth = 1
InnerTree.EnableConnectorLines = True
Unfortunately after postback i receive bad response from server here in js code:
/******************************************Callback Request Handler*********************************/
$IG.CallbackRequestHandler = function (manager, callbackObject, async)
...
try
{
obj = Sys.Serialization.JavaScriptSerializer.deserialize(response)
}
catch (e)
/* OK 2/7/2011 63320 - if a website times out and the framework re-directs the user to the login page
we should not process the response, but instead just display the login page */
if (response.indexOf("[") != 0 && (response.indexOf("<HTML") > -1 || response.indexOf("<html") > -1))
document.write(response); //call stack is showing that this line is executed
return;
failed = true;
me._manager._requestFailed(me, me._callbackObject, false, "Deserialization failure: Invalid response.");
It seems that reponse contains whole definition of page (like
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">....)
instead of json definition of tree. I suppose that it is because definition of data tree is in seperate dll and request is not handled properly.
Maybe i should manually add some input in config or handle this request diffrently.
We are using:
Infragistics4.Web.v11.1
11.1.20111.1006
Any suggestions.
Hello ppiwow,
If you still need assistance with the matter, please let me know.
Hi ppiwow,
I’m not sure I understand your question. Can you please clarify what is your scenario, what you would like to accomplish and what are the exact steps to reproduce the issue. Does the issue occurs if you place the WebDataTree directly on the page? Thank you.
Yes i need.
control is added to library in
Protected
Overrides Sub CreateChildControls()
with code
InnerTree = New WebDataTree() InnerTree.ID = Me.UniqueID InnerTree.DragDropSettings.DragDropMode = DragDropMode.Copy InnerTree.DragDropSettings.EnableDragDrop = True InnerTree.DragDropSettings.AllowDrop = False InnerTree.ClientEvents.DragEnter = "InnerTree_DragEnter" InnerTree.ClientEvents.NodeDropping = "InnerTree_DragEnter" InnerTree.EnableAjax = True InnerTree.EnableAjaxViewState = True InnerTree.EnableViewState = True InnerTree.InitialExpandDepth = 1 InnerTree.InitialDataBindDepth = 1 InnerTree.EnableConnectorLines = True
Controls.Add(InnerTree)
About rendering not sure what you are asking about.
In library i'm also binding data to data tree
Protected Overrides Sub OnPreRender(ByVal e As System.EventArgs) InnerTree.Nodes.Clear() InnerTree.DataSource = xmlTreeSource InnerTree.DataBind()
End Sub
Nothing else in this library is done with weddatatree.
Does it help?
Let me know if you still need assistance with the matter.
Can you please provide some more details about your implementation of WebDataTree - how do you add it to the library project and to the page. How is the tree rendered? A sample reproducing the issue would also be helpful.
Thank you.