How to change Repeater DataSourceID?
<p>I have a repeater and and and I set its <code>DataSourceID</code> .</p>

<pre><code>&lt;asp:Repeater ID="rpProducts" runat="server" DataSourceID="ItemDataSource" &gt;
    &lt;HeaderTemplate&gt;....&lt;/HeaderTemplate&gt;
    &lt;ItemTemplate&gt;
       ....
    &lt;/ItemTemplate&gt;
    &lt;FooterTemplate&gt;
    &lt;/FooterTemplate&gt;
&lt;/asp:Repeater&gt;
</code></pre>

<p>But I some time I want to change the <code>DataSourceID</code> and load data and again set the <code>ItemDataSource</code>.</p>

<p>This is my code for change the rpProducts <code>DataSourceID</code> .</p>

<pre><code>rpProducts.DataSourceID = null;
rpProducts.DataSource = goods;
rpProducts.DataBind();
</code></pre>

<p>So then again I want to set the <code>DataSourceID</code> to <code>ItemDataSource</code>.</p>

<p>How can I do it?</p>

<p>I try like this. but is not working</p>

<pre><code>    rpProducts.DataSourceID = null;
    rpProducts.DataSourceID = ItemDataSource.ToString();
</code></pre>
