You must Sign In to post a response.
  • Category: .NET

    How to arrange table in tr and td with single line border

    Leave Type dropdownlist From Date textbox1

    To Date textbox2 Reason textbox3

    for above format in html how to design in table using tr and td with single line border


    The below code i tried as follows

    <asp:Label ID="lbluser" runat="server" Text="Leave Type">
    <asp:DropDownList ID="ddlleavetype" runat="server">
    <asp:ListItem Enabled="true" Text="Select Leave Type" Value="-1">

    <asp:Label ID="lblfromdt" runat="server" Text="From Date">
    <asp:TextBox ID="textbox2" runat="server">

    <asp:Label ID="lbltodate" runat="server" Text="ToDate">
    <asp:TextBox ID="textbox1" runat="server">

    <asp:Label ID="lblreason" runat="server" Text="Reason">
    <asp:TextBox ID="textbox3" runat="server">

    what i tried the above code it is not working
  • #769531
    Hi Rao,

    I have prepared the table as your requirement. Refer the below codes,

    <table border="1" cellspacing="0" cellpadding="0">
    <tr style="height:40px;">
    <td>Leave Type:</td>
    <td style="padding:10px;">
    <asp:DropDownList ID="ddlleavetype" runat="server">
    <asp:ListItem Enabled="true" Text="Select Leave Type" Value="1" />
    </asp:DropDownList>
    </td>
    <td style="width: 50px;"></td>
    <td>From Date:</td>
    <td style="padding-left:10px;">
    <asp:TextBox ID="txtFromDate" runat="server" />
    </td>
    </tr>
    <tr>
    <td colspan="5" style="height:10px;"></td>
    </tr>
    <tr style="height:40px;">
    <td>To Date:</td>
    <td style="padding-left:10px;">
    <asp:TextBox ID="txtToDate" runat="server" />
    </td>
    <td style="width: 50px;"></td>
    <td>Reason:</td>
    <td style="padding-left:10px;">
    <asp:TextBox ID="txtReason" runat="server" />
    </td>
    </tr>
    </table>

    Regards,
    V.M. Damodharan
    "Your talent will be worthless, when you have fear and tension."


  • Sign In to post your comments