没有常识过
用 ObjectId=null
可以吗?

解决方案 »

  1.   

    <script language="JavaScript" type="text/JavaScript">
    function destroy(src){
    src.removeNode(true);
    }
    </script>removeNode Method  --------------------------------------------------------------------------------Removes the object from the document hierarchy.SyntaxoRemoved = object.removeNode( [bRemoveChildren])
    ParametersbRemoveChildren Optional. Boolean that specifies one of the following values: false Default. childNodes collection of the object is not removed. 
    true childNodes collection of the object is removed. 
     Return ValueReturns a reference to the object that is removed.ResThis property is accessible at run time. If elements are removed at run time, before the closing tag is parsed, areas of the document might not render.
      

  2.   

    mjpclab(我是大猫猫啊 mjpclab.8u8.com):
    谢谢 你的指点
    下次就知道了!
      

  3.   

    <html>
    <script language='javascript'>var count = 80000;
    var objects = new Array(count);function createObjects()
    {
    for (var i = 0; i < count; i ++)
    {
    objects[i] = new Object();
    }
    }function releaseObjects()
    {
    //under code block can not release the  memory. for (var i = 0; i < count; i ++)
    {
    objects[i] = null;
    }}</script><BODY>
    <input type='button' value='Create many objects' onclick='createObjects()'>
    <input type='button' value='Relase all objects ' onclick='releaseObjects()'>
    <br>please care about memory change....
    </BODY>
    </HTML>
      

  4.   

    Obj=null是不行的
    zhaoxiaoyang(梅雪香) 的初步测试可以的。
    刚才经过上机测试不能完全避免,但是出现ie报错减少,很感谢你。
    我想再经过几天的测试,看看效果。
    希望有更好的解决方案
      

  5.   

    我这个object是控件,不能用=null释放的,谢谢!
    我测试过,报出错误!!