title: ASP.Net ScriptControl - Call one method from another
body: <p>Say I have two script controls and one control has the other as a child control:</p>
  
  <pre><code>ParentControl : ScriptControl
  {
     ChildControl childControl;
  }
  </code></pre>
  
  <p>The script for the Child Control:</p>
  
  <pre><code>ChildControl = function(element) 
  {
    ChildControl.initializeBase(this, [element]);
  }
  
  ChildControl.prototype =
  {
      callMethod: function()
      {
        return 'hi';
      },
  
      initialize: function() 
      {
        ChildControl.callBaseMethod(this, 'initialize');
      },
  
      dispose: function() 
      {
        ChildControl.callBaseMethod(this, 'dispose');
      }
  }
  </code></pre>
  
  <p>And on script side I want to call a method on the child control:</p>
  
  <pre><code>ParentControl.prototype =
  {
      initialize: function() 
      {
        this._childControl = $get(this._childControlID);
        this._childControl.CallMethod();
  
        ParentControl.callBaseMethod(this, 'initialize');
      },
  
      dispose: function() 
      {
        ParentControl.callBaseMethod(this, 'dispose');
      }
  }
  </code></pre>
  
  <p>Problem is, everytime I try this is says this method isn't found or supported.  Shouldn't all methods on the ChildControl be accessible by the ParentControl?</p>
  
  <p>Is there some way I have to make the method public so that the ParentControl can see it?</p>
  
  <p><strong>Update</strong>
  Would it be possible to "type" the this._childControl?  </p>
  
  <p>Here's the reason I ask... When I use Watch, the system knows what the ChildControl class is, and I can call methods off the class itself, however, I can't call the same methods off the this._childControl object.  You would think that if the class design (?) in memory recognizes the method existing, and object instantiated from that class would too.</p>