缺少对象的问题,急!!!
<form name= "Form1 " method= "post " action= "Frm_Sales_Report.aspx " id= "Form1 ">
<input type= "hidden " name= "__VIEWSTATE " value= "dDwtNjU0MzcyMTk1Ozs+Hke5sDlsS2tRk+byX+h+LkCqUBc= " />
<div id= "Div2>
<table id= "Dg ">
</table>
</div>
</form>
我怎么用 var tb=document.getElementById( 'Dg ');
和用document.all( 'Dg ')得到的值为null?
------解决方案--------------------因为你的代码有语法错误:
<div id= "Div2>
<table id= "Dg ">
第一行的id中缺少右引号。