| | |
Fix TD height Width + Repeater
Please support our ASP.NET advertiser: Intel Parallel Studio Home
![]() |
•
•
Join Date: Mar 2008
Posts: 324
Reputation:
Solved Threads: 7
SOURCE CODE
Only Probs is dat i want to fix the height & width of TD.See the Description (TD) is having too much height.I wnat to fix it.See i pic.
ASP.NET Syntax (Toggle Plain Text)
<asp:Repeater ID="Repeater1" runat="server"> <HeaderTemplate> <table border="1" width="100%"> <tr bgcolor=Gray> <th>ProductId</th> <th>ProductName</th> <th>Description</th> <th>Weight</th> <th>isInStock</th> </tr> </HeaderTemplate> <ItemTemplate> <tr> <td width ="10%" height ="50%"><%# DataBinder.Eval(Container.DataItem,"ProdID") %></td> <td width ="10%" height ="50%"><asp:HyperLink id="hlEdit" runat="server" NavigateUrl="Frmuser.aspx" Text='<%# DataBinder.Eval(Container.DataItem, "ProdName") %>'></asp:HyperLink></td> <td width ="10%" height ="50%" ><%# DataBinder.Eval(Container.DataItem,"Descr") %></td> <td width ="10%" height ="50%" ><%# DataBinder.Eval(Container.DataItem,"Weight") %></td> <td width ="10%" height ="50%" ><%# DataBinder.Eval(Container.DataItem,"islnStock") %></td> </tr> </ItemTemplate> <AlternatingItemTemplate> <tr bgcolor="#ccccff"> <td width ="10%" height ="50%"><%# DataBinder.Eval(Container.DataItem,"ProdID") %></td> <td width ="10%" height ="50%"><asp:HyperLink id="hlEdit" runat="server" NavigateUrl="Frmuser.aspx" Text='<%# DataBinder.Eval(Container.DataItem, "ProdName") %>'></asp:HyperLink></td> <td width ="10%" height ="50%" ><%# DataBinder.Eval(Container.DataItem,"Descr") %></td> <td width ="10%" height ="50%" ><%# DataBinder.Eval(Container.DataItem,"Weight") %></td> <td width ="10%" height ="50%" ><%# DataBinder.Eval(Container.DataItem,"islnStock") %></td> </tr> </AlternatingItemTemplate> <FooterTemplate> </table> </FooterTemplate> </asp:Repeater>
ASP.NET Syntax (Toggle Plain Text)
public partial class FrmMain : System.Web.UI.Page { SqlConnection conn = new SqlConnection(ConfigurationManager.ConnectionStrings["Connection"].ConnectionString); SqlDataAdapter da; DataSet ds = new DataSet(); string query; SqlCommand cmd; protected void Page_Load(object sender, EventArgs e) { try { da = new SqlDataAdapter("SELECT * FROM Products", conn); da.Fill(ds, "PRODUCTS"); Repeater1.DataSource = ds.Tables["PRODUCTS"]; Repeater1.DataBind(); } catch (Exception ex) { } }
Only Probs is dat i want to fix the height & width of TD.See the Description (TD) is having too much height.I wnat to fix it.See i pic.
![]() |
Similar Threads
- Get frame height and width (ASP.NET)
- Getting the height and width of content fitting DIV element. (JavaScript / DHTML / AJAX)
- How to get Image width and Height using JavaScript (JavaScript / DHTML / AJAX)
- width section (C++)
Other Threads in the ASP.NET Forum
- Previous Thread: ViewChanged Event is not firing
- Next Thread: Sending value of checkboxes to new page?
Views: 326 | Replies: 1
| Thread Tools | Search this Thread |
Tag cloud for ASP.NET
.net 2.0 activexcontrol advice ajax alltypeofvideos anathor asp asp.net bc30451 bottomasp.net browser button c# c#gridviewcolumn checkbox click commonfunctions confirmationcodegeneration courier css dataaccesslayer database datagridview datagridviewcheckbox datalist deadlock development dgv dropdownlist edit editing expose feedback flash form formatdecimal forms formview google grid gridview homeedition hosting iframe iis index javascript jquery list listbox login microsoft migration mono mouse mssql multistepregistration news numerical object objects panelmasterpagebuttoncontrols parent problem project radio reportemail richtextbox rotatepage save schoolproject search security session silverlight smartcard software sql-server sqlserver2005 suse textbox tracking unauthorized update validation vb.net video videos view virtualdirectory vista visualstudio web webapplications webdevelopemnt webprogramming webservice xml youareanotmemberofthedebuggerusers





