Refresh updatepanel after fixed interval
<p>This is my script:</p>

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

        setTimeout('myFun()', 10000);
     });

    function myFun() {
        var btn = document.getElementById('&lt;%=myBtn.ClientID %&gt;');
        alert(btn);
        btn.click();
     }
&lt;/script&gt;
</code></pre>

<p>My markup:</p>

<pre><code>&lt;asp:UpdatePanel ID="upMain" runat="server" UpdateMode="Conditional"&gt;
    &lt;ContentTemplate&gt;
        &lt;asp:Label ID="lblValue" runat="server" Text=""&gt;&lt;/asp:Label&gt;
    &lt;/ContentTemplate&gt;
    &lt;Triggers&gt;
        &lt;asp:AsyncPostBackTrigger ControlID="myBtn" EventName="Click" /&gt;
     &lt;/Triggers&gt;
&lt;/asp:UpdatePanel&gt;
&lt;asp:Button ID="myBtn" runat="server" Text="hit" /&gt;
</code></pre>

<p>Code Behind:</p>

<pre><code>protected void Page_Load(object sender, EventArgs e)
{
    if (!IsPostBack)
    {
        lblValue.Text = "0";
    }
    else
    {
        lblValue.Text = Convert.ToString(Convert.ToInt32(lblValue.Text) + 1);
    }
}
</code></pre>

<p>I need to refresh the updatepanel after every 10 seconds. But after page load, only once I'm able to achieve that. Is there anything I'm missing? Thanks.</p>
