Note that there are some explanatory texts on larger screens.

plurals
  1. PORecursive Hierarchical Joins with Depth
    text
    copied!<p>I followed this <a href="http://www.superstarcoders.com/blogs/posts/recursive-hierarchical-joins-in-c-sharp-and-linq.aspx" rel="nofollow"><strong>Recursive Hierarchical Joins in C# and LINQ</strong></a> post to implement recursive join extension to show a tree view data in my application. As i have 15000 tree nodes, the jQuery <a href="http://wwwendt.de/tech/dynatree/doc/dynatree-doc.html" rel="nofollow"><strong>DynaTree</strong></a> at client side preparation takes lot of time (50 Secs) in buggy browser I.E 7&amp;8</p> <p>To avoid this i decided to load only one level initially, then load other children on demand (Lazy Loading).</p> <p>But i could not see the effect in setting depth in recursive join. Even i specify, it prepare all nodes. </p> <pre><code>public static List&lt;DynaTreeNode&gt; GenerateTreeByDepth(List&lt;NodeDTO&gt; nodeList, int deepLevel) { StringBuilder hirTree = new StringBuilder(); List&lt;DynaTreeNode&gt; tree = new List&lt;DynaTreeNode&gt;(); IEnumerable&lt;DynaTreeNode&gt; nodes = nodeList.RecursiveJoin (element =&gt; element.DataPointSK,element =&gt; element.DataPointSKParent, (NodeDTO element, int index, int depth,IEnumerable&lt;DynaTreeNode&gt; childNodes) =&gt; new DynaTreeNode() { title = element.DataPoint, key = element.DataPointSK.ToString(), children = childNodes.ToList(), select = element.selected, expand = element.selected, Depth = deepLevel }); tree = nodes.ToList(); return tree; } </code></pre> <p>I tried setting depth </p> <blockquote> <p><strong>Depth = deepLevel</strong></p> </blockquote> <p>But no use. What could be the issue? How can i do this? </p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload