title: How to access properties of JS object in parent window from iFrame in IE7?
body: <p>I have a JS Object called CoolThing that exists in the top window.</p>
  
  <p>I have an iFrame, same domain as top window, that needs to access a property, CoolProperty, in CoolThing.</p>
  
  <p>The javascript in the iFrame to access CoolProperty, which works perfectly in FF, webkit, and IE8, is:</p>
  
  <pre><code>&lt;script type="text/javascript" charset="utf-8"&gt;
    with(window.parent) {
      this.CoolThing.CoolProperty.coolFunction();
    }
  &lt;/script&gt;
  </code></pre>
  
  <p>In IE7, i get the error: <code>this.CoolThing.CoolProperty</code> is null or not an object. I've tried inspecting CoolThing by iterating through its properties, but there are none according to IE7. It has no problem accessing this.CoolThing itself.. only it seems to think the object is empty.</p>
  
  <p>I've tried the above without the <code>with</code> statement and attempted calling window.parent.CoolThing.CoolProperty directly, which, again, has no problem executing in all browsers except for IE7, in which it gives the same error. </p>
  
  <p>Any tips?</p>