外面表格加cellSpacing="0" cellPadding="0"<TABLE id="Table1" cellSpacing="0" cellPadding="0">

解决方案 »

  1.   

    <%@ Page language="c#" Codebehind="WebForm1.aspx.cs" AutoEventWireup="false" Inherits="SunCode.WebForm1" %>
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
    <html>
    <head>
    <title>WebForm1</title>
    <meta content="Microsoft Visual Studio .NET 7.1" name="GENERATOR">
    <meta content="C#" name="CODE_LANGUAGE">
    <meta content="JavaScript" name="vs_defaultClientScript">
    <meta content="http://schemas.microsoft.com/intellisense/ie5" name="vs_targetSchema">
    </head>
    <body ms_positioning="GridLayout">
    <table id="Table1" style="WIDTH: 377px; HEIGHT: 24px" cellspacing="0" cellpadding="0" width="377"
    border="1">
    <tr>
    <td>
    <table id="Table2" cellspacing="1" cellpadding="1" width="372" border="1">
    <tr>
    <td></td>
    </tr>
    </table>
    </td>
    </tr>
    </table>
    </body>
    </html>
      

  2.   

    同意二楼的,加上
    cellSpacing=0 cellPadding=0 就ok
      

  3.   

    把height去掉<%@ Page language="c#" Codebehind="WebForm1.aspx.cs" AutoEventWireup="false" Inherits="SunCode.WebForm1" %>
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
    <html>
    <head>
    <title>WebForm1</title>
    <meta content="Microsoft Visual Studio .NET 7.1" name="GENERATOR">
    <meta content="C#" name="CODE_LANGUAGE">
    <meta content="JavaScript" name="vs_defaultClientScript">
    <meta content="http://schemas.microsoft.com/intellisense/ie5" name="vs_targetSchema">
    </head>
    <body ms_positioning="GridLayout">
    <table id="Table1" style="WIDTH: 377px;" cellspacing="0" cellpadding="0"
    border="1">
    <tr>
    <td>
    <table id="Table2" cellspacing="1" cellpadding="1" width="372" border="1">
    <tr>
    <td></td>
    </tr>
    </table>
    </td>
    </tr>
    </table>
    </body>
    </html>
      

  4.   

    重新整理一下,请帮看看,怀疑是.net的编辑环境的问题。总是自动加上style
    但不应该总是调不拢,两条底线之间总象多一行的距离。<body ms_positioning="GridLayout">
     <table id="Table1" style="WIDTH: 377px; HEIGHT: 24px" cellspacing="0" cellpadding="0" width="377"border="1">
       <tr>
        <td>
          <table id="Table2" cellspacing="1" cellpadding="1" width="372" border="1">
             <tr>
               <td></td>
    </tr>
          </table>
       </td>
      </tr>
     </table>
    </body>
      

  5.   

    把style="WIDTH: 377px; HEIGHT: 24px"中的HEIGHT: 24px去掉
      

  6.   

    或者把里面的table的height设为 100%
    <body ms_positioning="GridLayout">
     <table id="Table1" style="WIDTH: 377px; HEIGHT:24px" cellspacing="0" cellpadding="0" width="377"border="1">
       <tr>
        <td>
          <table id="Table2" style="height:100%"   cellspacing="1" cellpadding="1" width="372" border="1">
             <tr>
               <td></td>
    </tr>
          </table>
       </td>
      </tr>
     </table>
    </body>
      

  7.   

    <table id="Table2" cellspacing="0" cellpadding="0" width="300" border="0" style="WIDTH: 300px; HEIGHT:100%">果然是这个 HEIGHT 在做怪。我今晚可彻底的I服了它了。也感觉到.net的编辑环境如此的不好用。老给我自动加一些乱七八糟的东西。谢谢各位。 加分
      

  8.   

    你的TABLE2的HEIGHT呢?
    設為100% 或和TABLE1 的一樣。
    我想就差不多了吧
      

  9.   

    就這樣,我試過了,行的<html>
    <head>
    <title>WebForm1</title>
    <meta content="Microsoft Visual Studio .NET 7.1" name="GENERATOR">
    <meta content="C#" name="CODE_LANGUAGE">
    <meta content="JavaScript" name="vs_defaultClientScript">
    <meta content="http://schemas.microsoft.com/intellisense/ie5" name="vs_targetSchema">
    </head>
    <body ms_positioning="GridLayout">
    <table id="Table1" style="WIDTH: 377px; HEIGHT: 24px" cellspacing="0" cellpadding="0" width="377"
    border="1">
    <tr>
    <td>
    <table id="Table2" cellspacing="1" cellpadding="1" width="372" height=100% border="1">
    <tr>
    <td></td>
    </tr>
    </table>
    </td>
    </tr>
    </table>
    </body>
    </html>
      

  10.   

    yfelix(贝贝) 
    确实可以的
      

  11.   

    <%@ Page language="c#" Codebehind="WebForm1.aspx.cs" AutoEventWireup="false" Inherits="SunCode.WebForm1" %>
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
    <html>
    <head>
    <title>WebForm1</title>
    <meta content="Microsoft Visual Studio .NET 7.1" name="GENERATOR">
    <meta content="C#" name="CODE_LANGUAGE">
    <meta content="JavaScript" name="vs_defaultClientScript">
    <meta content="http://schemas.microsoft.com/intellisense/ie5" name="vs_targetSchema">
    </head>
    <body ms_positioning="GridLayout">
    <table id="Table1" style="WIDTH: 377px;" cellspacing="0" cellpadding="0"
    border="1">
    <tr>
    <td>
    <table id="Table2" cellspacing="1" cellpadding="1" width="372" border="1">
    <tr>
    <td></td>
    </tr>
    </table>
    </td>
    </tr>
    </table>
    </body>
    </html>