Retrieving ListView using FindControl
<p>I am trying to retrieve two listviews from an ascx control for the purpose of saving them to a PDF file: </p>

<pre><code>&lt;TagCloud:TagCloudControl ID="TagCloudControl1" runat="server" /&gt;
</code></pre>

<p>I get the following error: TagCloudControl1 is a field but is used like a type and an object reference is required for the non-static field, method or property...Thanks for your help!</p>

<pre><code>ListView lv1 = (TagCloudControl1)ListView.FindControl("ListView1");
ListView lv2 = (TagCloudControl1)ListView.FindControl("ListView2");

lv1.RenderControl(htWriter);
lv2.RenderControl(htWriter);
</code></pre>
