title: Calling javascript when a partial view is loaded
body: <p>I have an ASP.NET MVC application. In the application, I have a page with a button on it. When I click on the button a partial view is rendered in a window (see below). Inside the view I have a combo box and I need to load the combo box after the view is rendered. I tried to call the js right after win.show() but that doesn't work because the textbox used to render combo is inside the partial view. When should I call the js? Any help regarding this will be highly appreciated. Thanks!</p>
  
  <pre><code>var win;
  if (!win) {
      win = new Ext.Window({
          layout: 'fit',
          width: 750,
          height: 630,
          closeAction: 'hide',
          plain: true,
          autoLoad: {
              url: '../SearchJob/SearchPanel'
          },
          buttons: [{
              text: 'Submit',
              handler: function () { }
          }, {
              text: 'Close Me',
              handler: function () {
                  win.hide();
              }
          }]
      });
  }
  win.show(this);
  
  }
  </code></pre>