title: ExtJs Change Tree Root
body: <p>Helo :)</p>
  
  <p>I have a TreePanel (with a Button in its toolbar) with AsyncNode root. For some reason I need to change tree content when Button is clicked. I call Ext.Ajax.request and it returns all necessary data. But how can I put it into my TreePanel?</p>
  
  <p>I tried following code, but it doesn't work :(</p>
  
  <pre><code>    Ext.Ajax.request({
          url: '../mocksearch',
          params: {
              pattern: txtSearch.getValue()
          },
          success: function(result, options) {
              searchResultRoot = Ext.decode(result.responseText);
              tree.setRootNode(searchResultRoot);                 
          }
      });
  </code></pre>