How to get the object of Iframe at clientside(javascript) which placed inside Table in asp.net
<p>I have iframe inside the column of <code>&lt;asp:table&gt;</code>. I want to get the object of an iframe in javascript. I tried like this in <code>&lt;body&gt;</code> section:</p>

<pre><code>&lt;script type="text/javascript"&gt;
    function resizeIframe()
    {
        var height = document.documentElement.clientHeight;
        height -= document.getElementById('frame').offsetTop;
        height -= 20;         
        document.getElementById('frame').style.height = height + "px";
    };

    document.getElementById('frame').onload = resizeIframe;
    window.onresize = resizeIframe;
&lt;/script&gt;
</code></pre>

<p>But I'm getting error like <em>"object expected or null"</em>.</p>
