﻿<?xml version="1.0" encoding="utf-8"?><rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:media="http://search.yahoo.com/mrss/" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0"><channel><title>Intersoft Community - WebGrid Enterprise - self referencing grid causes auto-expand of child rows on update</title><link>http://www.intersoftsolutions.com/Community/WebGrid/self-referencing-grid-causes-auto-expand-of-child-rows-on-update/</link><description /><generator>http://www.intersoftsolutions.com</generator><language>en</language><copyright>Copyright 2002 - 2015 Intersoft Solutions Corp. All rights reserved.</copyright><ttl>60</ttl><item><title>self referencing grid causes auto-expand of child rows on update</title><link>http://www.intersoftsolutions.com/Community/WebGrid/self-referencing-grid-causes-auto-expand-of-child-rows-on-update/</link><pubDate>Sun, 05 Jul 2015 16:03:41 GMT</pubDate><dc:creator>yudi</dc:creator><description>&lt;p&gt;&lt;span style="color: #1f497d;"&gt;Glad to hear the good news.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color: #1f497d;"&gt;Should you need further assistance or run into any problems regarding our controls, feel free to post it into our forum. We would be happy to assist you again.&lt;/span&gt;&lt;/p&gt;</description></item><item><title>self referencing grid causes auto-expand of child rows on update</title><link>http://www.intersoftsolutions.com/Community/WebGrid/self-referencing-grid-causes-auto-expand-of-child-rows-on-update/</link><pubDate>Thu, 02 Jul 2015 17:40:48 GMT</pubDate><dc:creator>questica</dc:creator><description>&lt;p&gt;Thank you :) That seems to work.&amp;nbsp;Collapsing all the children on update&amp;nbsp;definitely seems to be the best of all the options provided. &lt;br&gt;&lt;/p&gt;</description></item><item><title>self referencing grid causes auto-expand of child rows on update</title><link>http://www.intersoftsolutions.com/Community/WebGrid/self-referencing-grid-causes-auto-expand-of-child-rows-on-update/</link><pubDate>Thu, 02 Jul 2015 02:53:49 GMT</pubDate><dc:creator>yudi</dc:creator><description>&lt;p&gt;&lt;span style="color: #1f497d;"&gt;Deeply apologize for the delay in sending this.&lt;/span&gt;&lt;/p&gt;&lt;blockquote&gt;Or have you found any other solutions? I need to deliver this to a customer shortly.&lt;/blockquote&gt;
&lt;p&gt;&lt;span style="color: #1f497d;"&gt;Yes, I have another solutions. The idea is: simply have the self-reference row to collapsed again. I found that this idea can be implemented in &lt;strong&gt;OnAfterResponseProcess&lt;/strong&gt; client-side event.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="color: #1f497d;"&gt;Add following JavaScript function and register WebGrid1_OnAfterResponseProcess function to the grid's OnAfterResponseProcess client-side event.&lt;/span&gt;&lt;/p&gt;
&lt;pre&gt;&amp;lt;script type="text/javascript"&amp;gt;
    function WebGrid1_OnAfterResponseProcess(controlId, actionName, lastRequestObject, xmlResponseObject)
    {
        var grid = ISGetObject("WebGrid1");
            
        if (actionName=="UpdateRow")
            grid.GetSelectedObject().ToRowObject().CollapseSelfRefRow();

        return true;
    }
&amp;lt;/script&amp;gt;
    
&amp;lt;ISWebGrid:WebGrid ID="WebGrid1" runat="server" ...&amp;gt;
    &amp;lt;LayoutSettings ...&amp;gt;
        &amp;lt;ClientSideEvents OnAfterResponseProcess="WebGrid1_OnAfterResponseProcess" /&amp;gt;
    &amp;lt;/LayoutSettings&amp;gt;
    ...
&amp;lt;/ISWebGrid:WebGrid&amp;gt;&lt;/pre&gt;
&lt;p&gt;&lt;span style="color: #1f497d;"&gt;Hope this helps.&lt;/span&gt;&lt;/p&gt;</description></item><item><title>self referencing grid causes auto-expand of child rows on update</title><link>http://www.intersoftsolutions.com/Community/WebGrid/self-referencing-grid-causes-auto-expand-of-child-rows-on-update/</link><pubDate>Tue, 23 Jun 2015 20:14:01 GMT</pubDate><dc:creator>questica</dc:creator><description>&lt;p&gt;Yudi, is there a support number I can call to discuss further options for this issue? Or have you found any other solutions? I need to deliver this to a customer shortly.&lt;br&gt;&lt;/p&gt;</description></item><item><title>self referencing grid causes auto-expand of child rows on update</title><link>http://www.intersoftsolutions.com/Community/WebGrid/self-referencing-grid-causes-auto-expand-of-child-rows-on-update/</link><pubDate>Thu, 18 Jun 2015 20:41:52 GMT</pubDate><dc:creator>questica</dc:creator><description>&lt;p&gt;Performance is a definitely a concern, so if at all possible, I would like to avoid&amp;nbsp;using the LoadOnDemand.&amp;nbsp;Is there a fix without using LoadOnDemand? Some kind of&amp;nbsp;javascript fix&amp;nbsp;or something? &lt;/p&gt;&lt;p&gt;Also, probably related to the same original issue, if I edit a parent row and then start editing a child row to that parent the whole page freezes, not just the grid. There is no recover except refreshing the page.&lt;br&gt;&lt;/p&gt;</description></item><item><title>self referencing grid causes auto-expand of child rows on update</title><link>http://www.intersoftsolutions.com/Community/WebGrid/self-referencing-grid-causes-auto-expand-of-child-rows-on-update/</link><pubDate>Thu, 18 Jun 2015 03:07:45 GMT</pubDate><dc:creator>yudi</dc:creator><description>&lt;blockquote&gt;The grid is much slower to expand&lt;/blockquote&gt;&lt;p&gt;&lt;span style="color: #1f497d;"&gt;This is due to the LoadOnDemand behavior where the child rows will be retrieved and loaded when user click the expand button.&lt;/span&gt;&lt;/p&gt;
&lt;blockquote&gt;the lowest level child nodes have a '+' icon until I try to expand them (at which point the remove themselves).&lt;/blockquote&gt;
&lt;p&gt;&lt;span style="color: #1f497d;"&gt;This &lt;a href="http://www.intersoftpt.com/Support/WebGrid/Documentation/topic142.html" target="_blank"&gt;how-to article&lt;/a&gt; shows how to remove the (+) sign for self reference LoadOnDemand rows that contain no child row. In InitializeRow event at the server side, use &lt;strong&gt;e.Row.SelfRefChildNotExpandable = true&lt;/strong&gt; to remove the + button.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="color: #1f497d;"&gt;Hope this helps.&lt;/span&gt;&lt;/p&gt;</description></item><item><title>self referencing grid causes auto-expand of child rows on update</title><link>http://www.intersoftsolutions.com/Community/WebGrid/self-referencing-grid-causes-auto-expand-of-child-rows-on-update/</link><pubDate>Wed, 17 Jun 2015 17:15:53 GMT</pubDate><dc:creator>questica</dc:creator><description>&lt;p&gt;Thanks for the quick response. &lt;/p&gt;&lt;p&gt;I tried seting LoadOnDemand to true and the child nodes no longer auto-expand.. however, there are 2 other issues that are raised. The grid is much slower to expand *and* the lowest level child nodes have a '+' icon until I try to expand them (at which point the remove themselves).&lt;/p&gt;&lt;p&gt;Do you have any further suggestions?&lt;br&gt;&lt;/p&gt;</description></item><item><title>self referencing grid causes auto-expand of child rows on update</title><link>http://www.intersoftsolutions.com/Community/WebGrid/self-referencing-grid-causes-auto-expand-of-child-rows-on-update/</link><pubDate>Wed, 17 Jun 2015 08:29:17 GMT</pubDate><dc:creator>yudi</dc:creator><description>&lt;p&gt;&lt;span style="color: #1f497d;"&gt;I modified SelfReferencingGrid.aspx sample file of WebGrid by enabling &lt;em&gt;AllowAddNew&lt;/em&gt;, &lt;em&gt;AllowDelete&lt;/em&gt;, and &lt;em&gt;AllowEdit&lt;/em&gt; feature. Next, modify &lt;strong&gt;Steven Buchanan&lt;/strong&gt;'s city from London to Manchester.&lt;br&gt;And yes, the reported problem is reproducible. After update, it auto-expands the edited row &amp;amp; all children. and it leave the '+' icon on the newly expanded rows so that the user needs to click the icon twice to actually collapse each row.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color: #1f497d;"&gt;I found that after enabling &lt;em&gt;LoadOnDemand&lt;/em&gt; property of &lt;em&gt;SelfReferencingSettings&lt;/em&gt;, the problem is no longer persist. Could you please try this solution and let me know how it works in your end?&lt;/span&gt;&lt;/p&gt;</description></item><item><title>self referencing grid causes auto-expand of child rows on update</title><link>http://www.intersoftsolutions.com/Community/WebGrid/self-referencing-grid-causes-auto-expand-of-child-rows-on-update/</link><pubDate>Mon, 15 Jun 2015 16:26:33 GMT</pubDate><dc:creator>questica</dc:creator><description>&lt;p&gt;(just incorrectly posted this as a discussion. it's a question.)&lt;/p&gt;&lt;p&gt;i've implemented a self referencing hierarchical webgrid with editable child/parent rows.&lt;/p&gt;&lt;p&gt;after editing a parent row, the row itself as well as all child rows auto-expand. the rows still keep the '+' icon causing the user to need to click on it twice to collapse again.&lt;/p&gt;&lt;p&gt;(attached photo)&lt;/p&gt;&lt;p&gt;is there a solution that prevents the expanding of the rows?&lt;br&gt;&lt;/p&gt;</description></item></channel></rss>