﻿<?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 - WebDesktop - How to disable WebPane?</title><link>http://www.intersoftsolutions.com/Community/WebDesktop/How-to-disable-WebPane/</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>How to disable WebPane?</title><link>http://www.intersoftsolutions.com/Community/WebDesktop/How-to-disable-WebPane/</link><pubDate>Sun, 26 Sep 2010 23:15:39 GMT</pubDate><dc:creator>yudi</dc:creator><description>&lt;p&gt;&lt;span style="font-family: 'segoe ui','sans-serif'; color: #1f497d; font-size: 9pt;"&gt;Currently I have no better idea to implement such scenario or to speed it up.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: 'segoe ui','sans-serif'; color: #1f497d; font-size: 9pt;"&gt;About the JS error, could you please let us know in detail about how to reproduce the issue? You may modify my sent sample and let us know the step-by-step to reproduce the issue (include the version of the browser).&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: 'segoe ui','sans-serif'; color: #1f497d; font-size: 9pt;"&gt;Hope this helps.&lt;/span&gt;&lt;/p&gt;</description></item><item><title>How to disable WebPane?</title><link>http://www.intersoftsolutions.com/Community/WebDesktop/How-to-disable-WebPane/</link><pubDate>Fri, 24 Sep 2010 13:49:16 GMT</pubDate><dc:creator>SAgosto</dc:creator><description>&lt;blockquote&gt;&lt;p&gt;&lt;span style="font-size: 9pt; color: #1f497d; font-family: 'segoe ui','sans-serif'"&gt;By default, there is no property or methods that can be used to implement your specific scenario, to disable WebPane include underlying controls that located inside.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="font-size: 9pt; color: #1f497d; font-family: 'segoe ui','sans-serif'"&gt;I’d like to offer a solution by using following Javascript function. Here is the scenario of the test page in my local end. There is a page that has a simple layout of WebPaneManager. In the “Header” pane, a WebCombo is added. Yet, an HTML button is added into the page. This button will be used to toggle the disable condition of the “Header” pane (include its underlying controls).&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="font-size: 9pt; color: #1f497d; font-family: 'segoe ui','sans-serif'"&gt;The idea is quite simple. First, get the div element of the content from the specific pane that we would like to disable/enable. Next, iterates through the childNodes of the content and set its disabled property to false or true.&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;function button1_onclick() {
    var WebPaneManager1 = ISGetObject("WebPaneManager1");
    var divContainer = WebPaneManager1.RootGroupPane.Panes[0].GetContentDivElement();

    toggleDisabled(divContainer);

    return true;
}

function toggleDisabled(el) {
    try {
        el.disabled = el.disabled ? false : true;
    }
    catch (E) {
    }

    if (el.childNodes &amp;amp;&amp;amp; el.childNodes.length &amp;gt; 0) {
        for (var x = 0; x &amp;lt; el.childNodes.length; x&amp;#43;&amp;#43;) {            
            toggleDisabled(el.childNodes[x]);
        }
    }
    return true;
}&lt;/pre&gt;&lt;p&gt;&lt;span style="font-size: 9pt; color: #1f497d; font-family: 'segoe ui','sans-serif'"&gt;I enclosed my test page as attachment. Please have the attach sample tested on your end and let us know whether it helps or not.&lt;/span&gt;&lt;/p&gt;&lt;/blockquote&gt;

&lt;p&gt; &lt;/p&gt;
&lt;p&gt;Thank you. This works good. The only issue is that you get a JS error if you click on the Grid's FilterRow ARROW icon. That's not a big deal. Do you think there is a way to speed it up? Or is the only wat recursion?&lt;/p&gt;</description></item><item><title>How to disable WebPane?</title><link>http://www.intersoftsolutions.com/Community/WebDesktop/How-to-disable-WebPane/</link><pubDate>Fri, 24 Sep 2010 05:24:50 GMT</pubDate><dc:creator>yudi</dc:creator><description>&lt;p&gt;&lt;span style="font-family: 'segoe ui','sans-serif'; color: #1f497d; font-size: 9pt"&gt;By default, there is no property or methods that can be used to implement your specific scenario, to disable WebPane include underlying controls that located inside.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: 'segoe ui','sans-serif'; color: #1f497d; font-size: 9pt"&gt;I’d like to offer a solution by using following Javascript function. Here is the scenario of the test page in my local end. There is a page that has a simple layout of WebPaneManager. In the “Header” pane, a WebCombo is added. Yet, an HTML button is added into the page. This button will be used to toggle the disable condition of the “Header” pane (include its underlying controls).&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family: 'segoe ui','sans-serif'; color: #1f497d; font-size: 9pt"&gt;The idea is quite simple. First, get the div element of the content from the specific pane that we would like to disable/enable. Next, iterates through the childNodes of the content and set its disabled property to false or true.&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;function button1_onclick() {
    var WebPaneManager1 = ISGetObject("WebPaneManager1");
    var divContainer = WebPaneManager1.RootGroupPane.Panes[0].GetContentDivElement();

    toggleDisabled(divContainer);

    return true;
}

function toggleDisabled(el) {
    try {
        el.disabled = el.disabled ? false : true;
    }
    catch (E) {
    }

    if (el.childNodes &amp;amp;&amp;amp; el.childNodes.length &amp;gt; 0) {
        for (var x = 0; x &amp;lt; el.childNodes.length; x&amp;#43;&amp;#43;) {            
            toggleDisabled(el.childNodes[x]);
        }
    }
    return true;
}&lt;/pre&gt;
&lt;p&gt;&lt;span style="font-family: 'segoe ui','sans-serif'; color: #1f497d; font-size: 9pt"&gt;I enclosed my test page as attachment. Please have the attach sample tested on your end and let us know whether it helps or not.&lt;/span&gt;&lt;/p&gt;</description></item><item><title>How to disable WebPane?</title><link>http://www.intersoftsolutions.com/Community/WebDesktop/How-to-disable-WebPane/</link><pubDate>Thu, 23 Sep 2010 16:14:30 GMT</pubDate><dc:creator>SAgosto</dc:creator><description>&lt;p&gt;Is there a way to disable a WebPane control? The WebPaneManager has a Disabled property which disables all of the panes but I have a need to disable a particular pane so the user cannot update any of the underlying controls.&lt;/p&gt;</description></item></channel></rss>