title: ASP.NET C# open dialog box from code behind
body: <p>I need to open a Jquery dialog box from a server side script in ASP.NET C#.</p>
  
  <p>Here is what the dialog box looks like in Jquery:</p>
  
  <pre><code>    $("#dialog-confirm").dialog({            
          resizable: false,
          modal: true,
          title: "Modal",
          height: 250,
          width: 400,
  
          buttons: {
              "Register": function () {
  
              },
              "Cancel": function () {
                  $(this).dialog('close');                    
              }
          }
      });
  </code></pre>
  
  <p>I need the code to call this dialog box from the code behind I am trying to us something like;</p>
  
  <pre><code>  ScriptManager.RegisterStartupScript(this.GetType(), "Pop", " $('#dialog-confirm').dialog('open');", true);
  </code></pre>
  
  <p>Need help in using the most appropriate way to open a dialog box from the code behind as what I have does not work. Nothing happens   </p>