jQuery DatePicker and .NET- one calendar control but multiple instances on one .aspx page
<p>Scenario: I have an .aspx page containing multiple collapsible panels.  Each panel represents a different report.  To run a report, you click a panel and the report's user controls will appear.  The date range control I created could be contained "within" more than one panel. </p>

<p>The code below does not work in the multiple panels instance.  It sets all of the "to date" text boxes equal to the start date instead of just the active panel's "to date" text box.</p>

<p>How do I only work with the text boxes in the panel I have expanded?</p>

<p>Thanks for your help!</p>

<pre><code>&lt;script type="text/javascript"&gt;
  $(document).ready(function(){
    $('#dFrom').datepicker();
    $('#dTo').datepicker();

    $('#dTo').click(function(){
    try{    

        var from = $('#dFrom').datepicker("getDate");

        $('#dTo').datepicker("setDate",from);

        }
        catch(Error)
        {
        alert(Error);
        }
    });
  });
</code></pre>
