Weird behavior in asp.net - asp.net

Can someone tell one why do i get the blue line that i show here: (and also it is really a good practice to define a class for just text-align:center instead of inline code?)
Code:
<asp:Panel ID="PnlBarraFinalizarMostrar" runat="server" CssClass="izq">
<asp:LinkButton ID="LkBRegresar" runat="server" CssClass="LKBPequeño" OnClick="LkBRegresar_Click">Regresar</asp:LinkButton>
</asp:Panel>
<%--alumn's info--%>
<asp:Panel ID="PnlAlumno" runat="server" BackColor="Yellow">
<table runat="server" class="datos" style="background-color:Green;">
<tr>
<td rowspan="4" style="width: 65px;">
<asp:Image ID="ImgAlumno" runat="server" BorderWidth="0px"
Width="62.7" Height="84" />
</td>
<td style="width: 75px;">
Alumno:
</td>
<td style="width:225px; white-space:nowrap;">
<asp:Label ID="LbDAlumno" runat="server" />
</td>
<td style="width: 40px;">
Ciclo:
</td>
<td>
<asp:Label ID="LbDciclo" runat="server" />
</td>
</tr>
<tr>
<td>
Carrera:
</td>
<td>
<asp:Label ID="LbDCarrera" runat="server" />
</td>
<td>
Plan:
</td>
<td>
<asp:Label ID="LbDPlan" runat="server" />
</td>
</tr>
<tr>
<td>
Maximo UV:
</td>
<td>
<asp:Label ID="LbDMaximoUV" runat="server" />
</td>
<td>
CUM:
</td>
<td>
<asp:Label ID="LbDCum" runat="server" />
</td>
</tr>
<tr style="vertical-align: text-top; background-color:Gray;">
<td>
UV Inscritas:
</td>
<td>
<asp:Label ID="LbDUVInscritas" runat="server" />
</td>
<td>
Avance:
</td>
<td>
<asp:Label ID="LbDAvance" runat="server" />
</td>
</tr>
</table>
</asp:Panel>
<br />
<%--Detalle de Asignaturas--%>
<asp:Panel ID="PnlHojaAsesoriaCursosInscritos" runat="server" Width="100%" BackColor="Sienna">
<table class="encabezado">
<tr>
<td>
<asp:Label ID="lbTituloHAsesoriaCInscritos" runat="server" Text="Hoja Asesoria o Cursos Inscritos" />
</td>
</tr>
</table>
<table id="THojaA" runat="server" class="tabla" style="padding:0px;background-color:Red;">
...
encabezado.css (header)
.encabezado
{
font-size:10pt;
text-align:left;
background-color:#152B81; color:#FFFFFF;
border-spacing: 2px;
padding:3px 4px 2px 5px;
width:100%;
}
datos.css (data)
.datos
{
font-size: 9pt;
border: 1px solid #152B81;
background-color: #DBE7F6;
color: #152B81;
width: 100%;
text-align: left;
border-spacing:0px;
padding:4px 4px 4px 5px;
}
after using inspection i detect a border-bottom!:
inspector:

Use inspect element to check what is happening once the code is parsed. or you can post the parsed html here.

Related

Align image to left is not working. Tried text-align, float, etc

Hi I am a beginner in ASP.Net. I have a web page that was working yesterday but now it's broken. I tried every solution that I found but it's not working. I'm sorry if there is a duplicate question but the solution didn't work for me.
Can you please help me.
My Code is:
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<link href="bootstrap.min.css" rel="stylesheet" />
<link href="bootstrap.min.js" rel="stylesheet" />
<link href="bootbox.js" rel="stylesheet" />
<link href="bootbox.min.js" rel="stylesheet" />
<link href="jquery.js" rel="stylesheet" />
<link href ="jquery-1.11.3.min.js" rel="stylesheet" />
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script>
<script src="bootstrap.min.js"></script>
<script src="bootbox.min.js"></script>
<title>
</title>
<style type="text/css">
.auto-style1 {
width: 100%;
}
.auto-style2 {
height: 23px;
}
.auto-style3 {
width: 252px;
}
.auto-style4 {
height: 23px;
width: 252px;
}
.auto-style5 {
width: 381px;
}
.auto-style6 {
height: 23px;
width: 381px;
}
#ImageButton2{
position: absolute;
top: 0px;
right: -1px; }
.auto-style7 {
width: 5px;
}
.auto-style8 {
height: 23px;
width: 5px;
}
#Image2{
float:left;
text-align: left;
}
.left{
float:left;
}
.test{
float:left;
text-align: left;
}
</style>
<script type="text/javascript" lang="javascript">
function pLogin() {
var result;
bootbox.confirm("Do you have an existing account?", function (result) {
if (result == true) {
window.location.href ="/login.aspx"
}
else
{}
});
return false
}
</script>
</head>
<body>
<form id="form1" runat="server">
<div>
<table class="auto-style1">
<tr>
<td class="auto-style7"> </td>
<td class="auto-style3"> </td>
<td class="auto-style5"> </td>
<td> </td>
<td> </td>
</tr>
<tr>
<td class="auto-style8">
</td>
<td class="auto-style4">
<asp:ImageButton ID="ImageButton1" runat="server" Height="113px" ImageUrl="~/images/baby's logo.png" Width="407px" />
</td>
<td class="auto-style6"> </td>
<td class="auto-style2"></td>
<td class="auto-style2">
<asp:ImageButton ID="ImageButton2" runat="server" Height="111px" ImageUrl="~/images/ordernow.jpg" Width="135px" OnClientClick="javascript: return pLogin();" />
</td>
</tr>
</table>
</div>
<div>
<hr />
</div>
<div>
<p class="test">
<asp:Image ID="Image2" runat="server" Height="500px" Style="float:left" ImageUrl="~/images/puto cake.jpg" Width="960px" />
</p>
</div>
<div>
</div>
<div>
<table class="nav-justified">
<tr>
<td class="auto-style11"> </td>
<td class="auto-style22">
<asp:Label ID="Label1" runat="server" Font-Bold="False" Font-Names="Tw Cen MT Condensed Extra Bold" ForeColor="Gray" Text="ORDER" ViewStateMode="Enabled" Width="100px"></asp:Label>
</td>
<td class="auto-style22">
<asp:Label ID="Label2" runat="server" Font-Bold="False" Font-Names="Tw Cen MT Condensed Extra Bold" ForeColor="Gray" Text="CUSTOMER SERVICE" ViewStateMode="Enabled" Width="239px"></asp:Label>
</td>
<td class="auto-style16">
<asp:Label ID="Label3" runat="server" Font-Bold="False" Font-Names="Tw Cen MT Condensed Extra Bold" ForeColor="Gray" Text="MY ACCOUNT" ViewStateMode="Enabled" Width="100px"></asp:Label>
</td>
<td>
<asp:Label ID="Label4" runat="server" Font-Bold="False" Font-Names="Tw Cen MT Condensed Extra Bold" ForeColor="Gray" Text="CONNECT WITH BABY'S PUTO CAKE" ViewStateMode="Enabled" Width="317px"></asp:Label>
</td>
</tr>
<tr>
<td class="auto-style17"></td>
<td class="auto-style23">
<asp:HyperLink ID="HyperLink1" runat="server" Font-Names="Arial Black" ForeColor="Black">Puto Cake</asp:HyperLink>
</td>
<td class="auto-style23">
<asp:HyperLink ID="HyperLink2" runat="server" Font-Names="Arial Black" ForeColor="Black">Contact Us</asp:HyperLink>
</td>
<td class="auto-style20">
<asp:HyperLink ID="HyperLink3" runat="server" Font-Names="Arial Black" ForeColor="Black">Create an Account</asp:HyperLink>
</td>
<td class="auto-style21">
<asp:ImageButton ID="ImageButton3" runat="server" Height="36px" ImageUrl="~/images/Facebook-128 (1).png" Width="44px" />
<asp:ImageButton ID="ImageButton4" runat="server" Height="36px" ImageUrl="~/images/Twitter-Bird-128 (1).png" Width="44px" />
<asp:ImageButton ID="ImageButton5" runat="server" Height="36px" ImageUrl="~/images/youtube_circle_color-512.png" Width="44px" />
</td>
</tr>
<tr>
<td class="auto-style11"> </td>
<td class="auto-style22"> </td>
<td class="auto-style22"> </td>
<td class="auto-style16">
<asp:HyperLink ID="HyperLink4" runat="server" Font-Names="Arial Black" ForeColor="Black">Sign In</asp:HyperLink>
</td>
<td> </td>
</tr>
<tr>
<td class="auto-style11"> </td>
<td class="auto-style22"> </td>
<td class="auto-style22"> </td>
<td class="auto-style16"> </td>
<td> </td>
</tr>
<tr>
<td class="auto-style11"> </td>
<td class="auto-style22"> </td>
<td class="auto-style22"> </td>
<td class="auto-style16"> </td>
<td> </td>
</tr>
</table>
</div>
</form>
<div>
<br />
<br />
<br />
</div>
</body>
</html>
As I could see you didn't make you images like block elements (images are inline elements by default). Try try use display: block; or display: inline-block; in your CSS classes and then use text-align: left;.
Also floated elements could behave wrong, because they "condensed" to the content even if you use a block level element. So also try to delete float rules from CSS classes or use clear:left;.

How do I pass a parameter in an asp onclick call in a table row?

Here I have a table row in a listview declared as follows:
<tr onclick="<%= _jsPostBackCall %>;" />
I am calling a postback method on the backend but must get the tr index:
public void RaisePostBackEvent(string eventArgument)
{
//selected index here
}
aspx page content - below is the html in the aspx page. This contains the listview.
<asp:ListView ID="lvEquipmentList" runat="server" OnSelectedIndexChanged="lvEquipmentList_SelectedIndexChanged" OnSelectedIndexChanging="lvEquipmentList_SelectedIndexChanging">
<LayoutTemplate>
<table runat="server" class="TableCSS">
<tr runat="server" class="TableHeader">
<td runat="server" style="width: 30%;">PRODUCT LINE</td>
<td runat="server" style="width: 20%;">MODEL</td>
<td runat="server" style="width: 20%;">SERIAL #</td>
<td runat="server" style="width: 12%; text-align:center">DAR STATUS</td>
<td runat="server" style="width: 18%; text-align:right;">SHIP DATE</td>
</tr>
<tr id="ItemPlaceholder" runat="server">
</tr>
</table>
</LayoutTemplate>
<EmptyDataTemplate>
<table id="Table1" runat="server" class="TableCSS">
<tr runat="server" class="TableHeader">
<td id="Td1" runat="server" style="width: 30%;">PRODUCT LINE</td>
<td id="Td2" runat="server" style="width: 20%;">MODEL</td>
<td id="Td3" runat="server" style="width: 20%;">SERIAL #</td>
<td id="Td4" runat="server" style="width: 12%; text-align:center;">DAR STATUS</td>
<td id="Td5" runat="server" style="width: 18%; text-align:right;">SHIP DATE</td>
</tr>
<tr runat="server" class="TableData">
<td style="column-span:all;">
<asp:Label runat="server" Text="There are no reports to display."></asp:Label>
</td>
</tr>
</table>
</EmptyDataTemplate>
<ItemTemplate>
<tr style="border-bottom:1pt solid #E2E2E8;" onclick="<%= _jsPostBackCall %>;" onmouseover="this.style.background='#f6f6f6';" onmouseout="this.style.background='white'">
<td style="width: 30%; padding: 0px 15px 0px 15px;">
<table>
<tr class="NoBorder">
<td style="width: 20%;">
<img src='<%#Eval("standard_image") %>' alt="" width="80" onerror="this.src='Content/Images/placeholder.png';"/>
</td>
<td>
<asp:Label ID="lblProductLine" runat="server" Text='<%#Eval("product_line")%>'/>
</td>
</tr>
</table>
</td>
<td style="width: 24%; padding: 0px 15px 0px 15px;">
<asp:Label ID="lblModelNum" runat="server" Text='<%#Eval("model")%>'/>
</td>
<td style="width: 16%; padding: 0px 15px 0px 15px;">
<asp:Label ID="lblSerialNum" runat="server" Text='<%#Eval("serial_number")%>'/>
</td>
<td style="width: 12%; padding: 0px 15px 0px 15px; text-align:center;">
<asp:LinkButton runat="server" ID="SelectCategoryButton" CommandName="Select">
<img id="Img1" runat="server" src='<%#Eval("display_status") %>' alt="" width="20"/>
</asp:LinkButton>
</td>
<td style="width: 18%; padding: 0px 15px 0px 15px; text-align:right;">
<asp:Label ID="lblShipDate" runat="server" Text='<%#Eval("date")%>'/>
</td>
</tr>
</ItemTemplate>
</asp:ListView>
When registering postback call - second argument will be the parameter:
_jsPostBackCall = ClientScript.GetPostBackEventReference(this, "The Parameter");

VB Css background-color of a table within a ListView only paints the visible part of the table

Hi everyone thx for trying to help.
I have a ListView with a fixed y header.
The header of my ListView is actually another table formatted to fit the ListView Columns.
I have a JScrollPane and a javascript in order to keep the header fixed at top and to keep it aligned with the ListView columns when I scroll on X Axis.
All fine. Except for the part where i start scrolling from left to right, The header background color is green(as programmed in the css file) only for the visible part of the Table, meaning that as soon as i scroll to the right to see the remaining columns I can notice that the header table isnt colored anymore, its transparent.
Here is my css:
.listeResultat
{
max-height: 800px;
height: 800px;
overflow:hidden ;
border: 1px solid black;
background: #F3F6FA;
}
#parentFixed
{
height:800px;
background-color:#cccccc;
overflow:auto;
}
.headerFixed{
color:White;
background-color:green;
font-size:20px;
position:static;
z-index:222;
}
.headerFixed table td{
border: 1px solid #000000 ;
min-width: 150px;
}
.wrapperfixed{
height:600px;
font-size:20px;
}
/*Celui la ici si on voulais un header fixe vertical aligné a gauche*/
.wrapperfixed .lefter{
float:left;
width:100px;
height:800px;
background-color:red;
position:relative;
}
.wrapperfixed .content{
float:left;
}
.wrapperfixed .content table td{
border: 1px solid #000000 ;
min-width : 150px;
}
.wrapperfixed .content table th{
border: 1px solid #000000 ;
min-width: 150px;
}
and this is my asp page with the script and everything
<div class="listeResultat">
<!--début tableau des résultats-->
<div id="parentFixed">
<div class="headerFixed">
<table id="tableHeader">
<tr>
<td><asp:LinkButton ID="Q" runat="server"><%= getCellText("Q")%></asp:LinkButton></td>
<td> <asp:LinkButton ID="W" runat="server"><%= getCellText("W")%></asp:LinkButton></td>
<td> <asp:LinkButton ID="E" runat="server"><%= getCellText("E")%></asp:LinkButton></td>
<td> <asp:LinkButton ID="R" runat="server"><%= getCellText("R")%></asp:LinkButton></td>
<td><asp:LinkButton ID="T" runat="server"><%= getCellText("T")%></asp:LinkButton></td>
<td><asp:LinkButton ID="Y" runat="server"><%= getCellText("Y")%></asp:LinkButton></td>
<td><asp:LinkButton ID="U" runat="server"><%= getCellText("U")%></asp:LinkButton></td>
<td><asp:LinkButton ID="I" runat="server"><%= getCellText("I")%></asp:LinkButton></td>
<td><asp:LinkButton ID="O" runat="server"><%= getCellText("O")%></asp:LinkButton></td>
<td><asp:LinkButton ID="P" runat="server"><%= getCellText("P")%></asp:LinkButton></td>
<td><asp:LinkButton ID="S" runat="server"><%= getCellText("S")%></asp:LinkButton></td>
<td><asp:LinkButton ID="L4" runat="server"><%= getCellText("L4")%></asp:LinkButton></td>
<td><asp:LinkButton ID="L5" runat="server"><%= getCellText("L5")%></asp:LinkButton></td>
<td><asp:LinkButton ID="A" runat="server"><%= getCellText("A")%></asp:LinkButton></td>
<td><asp:LinkButton ID="D" runat="server"><%= getCellText("D")%></asp:LinkButton></td>
<td><asp:LinkButton ID="F" runat="server"><%= getCellText("F")%></asp:LinkButton></td>
<td><asp:LinkButton ID="G" runat="server"><%= getCellText("G")%></asp:LinkButton></td>
<td><asp:LinkButton ID="H" runat="server"><%= getCellText("H")%></asp:LinkButton></td>
<td><asp:LinkButton ID="J" runat="server"><%= getCellText("J")%></asp:LinkButton></td>
<td> <asp:LinkButton ID="K" runat="server"><%= getCellText("K")%></asp:LinkButton></td>
<td><asp:LinkButton ID="L" runat="server"><%= getCellText("L")%></asp:LinkButton></td>
<td> <asp:LinkButton ID="Z" runat="server"><%= getCellText("Z")%></asp:LinkButton></td>
<td> <asp:LinkButton ID="X" runat="server"><%= getCellText("X")%></asp:LinkButton></td>
<td> <asp:LinkButton ID="C" runat="server"><%= getCellText("C")%></asp:LinkButton></td>
<td><asp:LinkButton ID="V" runat="server"><%= getCellText("V")%></asp:LinkButton></td>
<td><asp:LinkButton ID="B" runat="server"><%= getCellText("B")%></asp:LinkButton></td>
<td><asp:LinkButton ID="N" runat="server"><%= getCellText("N")%></asp:LinkButton></td>
<td><asp:LinkButton ID="M" runat="server"><%= getCellText("M")%></asp:LinkButton></td>
<td><asp:LinkButton ID="QQ" runat="server"><%= getCellText("QQ")%></asp:LinkButton></td>
<td><asp:LinkButton ID="QW" runat="server"><%= getCellText("QW")%></asp:LinkButton></td>
<td><asp:LinkButton ID="QL" runat="server"><%= getCellText("QL")%></asp:LinkButton></td>
<td><asp:LinkButton ID="QE" runat="server"><%= getCellText("QE")%></asp:LinkButton></td>
<td><asp:LinkButton ID="QR" runat="server"><%= getCellText("QR")%></asp:LinkButton></td>
<td><asp:LinkButton ID="QT" runat="server"><%= getCellText("QT")%></asp:LinkButton></td>
<td><asp:LinkButton ID="QY" runat="server"><%= getCellText("QY")%></asp:LinkButton></td>
<td><asp:LinkButton ID="QU" runat="server"><%= getCellText("QU")%></asp:LinkButton></td>
<td><asp:LinkButton ID="COM" runat="server"><%= getCellText("COM")%></asp:LinkButton></td>
</tr>
</table>
</div><%--FIN HEADER FIXED--%>
<%--Wrapper FIXED--%>
<div class="wrapperfixed">
<div class="content"><%--Content FIXED--%>
<table>
<asp:ListView ID="ListView1" runat="server" EnableEventValidation="true">
<ItemTemplate>
<tr style="background-color: <%# BgColor(Eval("A"))%>">
<td width="106px">
<asp:Label runat="server" ID="lb_LB1"><%# Eval("Q")%></asp:Label>
</td>
<td width="106px">
<asp:Label runat="server" ID="lb_LB2"><%# Eval("W")%></asp:Label>
</td>
<td width="106px">
<asp:Label runat="server" ID="lb_LB3"><%# Eval("E")%></asp:Label></td>
<td width="106px">
<asp:Label runat="server" ID="lb_LB4"><%# Eval("R")%></asp:Label></td>
<td width="106px">
<asp:Label runat="server" ID="lb_LB5"><%# Eval("T")%></asp:Label></td>
<td width="106px">
<asp:Label runat="server" ID="lb_LB6"><%# Eval("Y")%></asp:Label></td>
<td width="106px">
<asp:Label runat="server" ID="lb_LB7"><%# Eval("U")%></asp:Label></td>
<td>
<asp:Label runat="server" ID="lb_LB8"><%# Eval("I")%></asp:Label></td>
<td>
<asp:Label runat="server" ID="lb_LB9"><%# Eval("O")%></asp:Label></td>
<td>
<asp:Label runat="server" ID="lb_LB10"><%# Eval("P")%></asp:Label></td>
<td>
<asp:Label runat="server" ID="lb_LB12"><%# Eval("S")%></asp:Label></td>
<td>
<asp:Label runat="server" ID="Label4"><%# Eval("L4")%></asp:Label></td>
<td>
<asp:Label runat="server" ID="Label5"><%# Eval("L5")%></asp:Label></td>
<td>
<asp:Label runat="server" ID="lb_LB11"><a href="Reservation.aspx?<%# getLink(Eval("A"), Eval("Q") , Eval("F"))%>"><%# Eval("A")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB13"><%# Eval("D")%></asp:Label></td>
<td>
<asp:Label runat="server" ID="lb_LB14"><%# Eval("F")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB15"><%# Eval("G")%></asp:Label></td>
<td>
<asp:Label runat="server" ID="lb_LB16"><%# Eval("H")%></asp:Label></td>
<td>
<asp:Label runat="server" ID="lb_LB17"><%# Eval("J")%></asp:Label></td>
<td>
<asp:Label runat="server" ID="lb_LB18"><%# Eval("K")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB19"><%# Eval("L")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB20"><%# Eval("Z")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB21"><%# Eval("X")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB22"><%# Eval("C")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB23"><%# Eval("V")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB24"><%# Eval("B")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB25"><%# Eval("N")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB26"><%# Eval("M")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB27"><%# Eval("QQ")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB28"><%# Eval("QW")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB29"><%# Eval("QL")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB30"><%# Eval("QE")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB31"><%# Eval("QR")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB32"><%# Eval("QT")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB33"><%# Eval("QY")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB34"><%# Eval("QU")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB35"><%# Eval("COM")%></asp:Label><%--Comments--%>
</td>
</tr>
</ItemTemplate>
<AlternatingItemTemplate>
<tr style="background-color: <%# BgColor(Eval("A"))%>">
<td style="width:106px;">
<asp:Label runat="server" ID="lb_LB1"><%# Eval("Q")%></asp:Label>
</td>
<td style="width:106px;">
<asp:Label runat="server" ID="lb_LB2"><%# Eval("W")%></asp:Label>
</td>
<td style="width:106px;">
<asp:Label runat="server" ID="lb_LB3"><%# Eval("E")%></asp:Label>
</td>
<td style="width:106px;">
<asp:Label runat="server" ID="lb_LB4"><%# Eval("R")%></asp:Label>
</td>
<td style="width:106px;">
<asp:Label runat="server" ID="lb_LB5"><%# Eval("T")%></asp:Label>
</td>
<td style="width:106px;">
<asp:Label runat="server" ID="lb_LB6"><%# Eval("Y")%></asp:Label>
</td>
<td style="width:106px;">
<asp:Label runat="server" ID="lb_LB7"><%# Eval("U")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB8"><%# Eval("I")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB9"><%# Eval("O")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB10"><%# Eval("P")%></asp:Label>
</td>
<%--<td><asp:Label runat="server" ID="Label1"><%# Eval("A")%></asp:Label></td>--%>
<td>
<asp:Label runat="server" ID="lb_LB12"><%# Eval("S")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="Label6"><%# Eval("L4")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="Label7"><%# Eval("L5")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB11"><%# Eval("A")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB13"><%# Eval("D")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB14"><%# Eval("F")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB15"><%# Eval("G")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB16"><%# Eval("H")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB17"><%# Eval("J")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB18"><%# Eval("K")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB19"><%# Eval("L")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB20"><%# Eval("Z")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB21"><%# Eval("X")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB22"><%# Eval("C")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB23"><%# Eval("V")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB24"><%# Eval("B")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB25"><%# Eval("N")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB26"><%# Eval("M")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB27"><%# Eval("QQ")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB28"><%# Eval("QW")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB29"><%# Eval("QL")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB30"><%# Eval("QE")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB31"><%# Eval("QR")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB32"><%# Eval("QT")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB33"><%# Eval("QY")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB34"><%# Eval("QU")%></asp:Label>
</td>
<td>
<asp:Label runat="server" ID="lb_LB35"><%# Eval("COM")%> </asp:Label><%--Comments--%>
</td>
</tr>
</AlternatingItemTemplate>
</asp:ListView>
</table>
</div><%--FIN CONTENT FIXED--%>
</div><%--FIN WRAPPER FIXED--%>
<div class="scrollarea"></div><%--Pour activer le javascript du jscrollpane--%>
</div><%--Fin ParentFixed--%>
<br/><br/>
<!-- styles pour le jScrollPane -->
<link type="text/css" href="Styles/jquery.jscrollpane.css" rel="stylesheet" media="all" />
<!-- jQuery direct de google -->
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js">
</script>
<!-- the mousewheel plugin - optional to provide mousewheel support -->
<script type="text/javascript" src="Scripts/jquery.mousewheel.js"></script>
<!-- the jScrollPane script -->
<script type="text/javascript" src="Scripts/jquery.jscrollpane.min.js"></script>
<%--Script qui ajoute un event lors de l'utilisation des scrollbar--%>
<script type="text/javascript">
$(document).ready(function () {
$('#parentFixed')
.bind('jsp-scroll-y',
function (event, scrollPositionY, isAtTop, isAtBottom) {
$(".headerFixed").css("top", scrollPositionY);
}
)
.bind('jsp-scroll-x',
function (event, scrollPositionX, isAtLeft, isAtRight) {
$(".lefter").css("left", scrollPositionX);
}
)
.jScrollPane();
});
// alert('I was invoked at the end of the script'); //test pour voir si le scripte roule
</script>
</div><%--FIN Div listeResultats--%>
<%--FIN PANEL DE LA LISTE DES RESULTATS--%>
Again I found the answer by myself. I have to tell my jquery script that each time the scroll right or left is used to paint the table background
This would be the needed line
$('#tableHeader').css('background-color', '#556d80');
This is the whole script
<script type="text/javascript">
$(document).ready(function () {
$('#parentFixed')
.bind('jsp-scroll-y',
function (event, scrollPositionY, isAtTop, isAtBottom) {
$(".headerFixed").css("top", scrollPositionY);
}
)
.bind('jsp-scroll-x',
function (event, scrollPositionX, isAtLeft, isAtRight) {
$(".lefter").css("left", scrollPositionX);
// $('#tableHeader').css('background-color', '#556d80');
$('#tableHeader').css({ 'background-image': 'url(Styles/grd_head.png)' });
}
)
.jScrollPane();
});
// alert('I was invoked at the end of the script'); //TRACE

how to use the img tag

i am a student working in an simple application and i do not know how to use the img tag and i have tryed one such code but while executing the code the image is not showing plz see the code and help me to saw what is the wrong in the code.
code is:
<asp:Content ID="Content3" ContentPlaceHolderID="MainContent" runat="server">
<table border="0" align="center" cellpadding="0" cellspacing="0" style="width: 100%;
height: 100%;">
<tr style="width: 100%; height: 300px;">
<td valign="middle" align="center">
<img alt="" src="C:\Documents and Settings\temp.intern1\My Documents\My Pictures\images4.jpg" />
</td>
</tr>
<tr style="height: 65%; vertical-align: top;">
<td style="width: 90%;" align="center">
<table cellpadding="0" cellspacing="0" width="100%">
<tr>
<td style="height: 20px">
</td>
</tr>
<tr>
<td align="center" valign="middle" width="100%" style="height: 100%">
<div id="Panel1" style="background-color: #87BDEF; height: 300px; width: 600px;">
<table cellpadding="0" cellspacing="0" style="height: 400px" width="600px">
<tr>
<td>
</td>
</tr>
<tr>
<td>
<table cellpadding="0" cellspacing="0" style="height: 200px" width="600px">
<tr>
<td align="right" style="padding-left: 5px; width: 50%;">
<asp:Label ID="lblUserName" runat="server" Text="USER NAME :"></asp:Label>
</td>
<td align="left" style="padding-left: 5px; width: 50%;">
<br />
<asp:TextBox ID="txtUserName" runat="server" Width="70%"></asp:TextBox>
<asp:RequiredFieldValidator ID="rfvUserName" ErrorMessage="Please enter Username"
ControlToValidate="txtUserName" runat="server" Width="70%" ForeColor="red" Style="margin-left: 0px;" />
</td>
</tr>
<tr>
<td>
<br />
</td>
<td>
<br />
</td>
</tr>
<tr>
<td align="right" style="width: 50%;">
<asp:Label ID="lblPassword" runat="server" Text="PASSWORD :"></asp:Label>
</td>
<td align="left" style="padding-left: 5px; width: 50%;">
<br />
<asp:TextBox ID="txtPassword" runat="server" TextMode="Password" Width="70%"></asp:TextBox>
<asp:RequiredFieldValidator ID="rfvPassword" ErrorMessage="Please enter Password"
ControlToValidate="txtPassword" runat="server" Width="70%" ForeColor="red" Style="margin-left: 0px" />
</td>
</tr>
<tr>
<td colspan="2" align="center">
<span id="lblInValid" style="color: #C00000; font-family: Verdana; font-size: Small;">
</span>
</td>
</tr>
<tr>
<td colspan="2" align="center">
<table width="50%">
<tr>
<td align="left" style="padding-left: 5px; width: 50%;">
<asp:Button ID="btnSubmit" runat="server" Text="SUBMIT" OnClick="btnSubmit_Click" />
<br />
<br />
<br />
</td>
<td align="left" style="padding-left: 5px; width: 50%;">
<asp:Button ID="btnClear" runat="server" Text="CLEAR" />
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td>
<br />
</td>
<td>
<br />
</td>
</tr>
</table>
</td>
</tr>
</table>
</div>
</td>
</tr>
<tr>
<td height="180px">
<br />
</td>
</tr>
<tr>
<td>
<br />
</td>
</tr>
</table>
</td>
</tr>
</table>
</asp:Content>
plz some one help me on this code...,
Your image should be in the folder accessible to your web server. Try including your image into your solution file (assuming you are using Visual Studio), and use relative path, such as "/images/image4.jpg"
Go to some web site (like www.cnn.com), view source for any page and see how they set path to img tags.
You can also use ASP.Net image tag, check out MSDN for examples and usage.
The problem is that you are using an address to an image on your computer, so that will only work when you view the page from that specific computer.
You should copy the image into the web application, for example into a folder named images, then you use that address in the image tag:
<img alt="" src="images/images4.jpg" />

Difference between web controls rendering and html table properties using ASP.NET

I'm designing a website in ASP.NET and I want to build table with some text, textboxes and validators in it. The problem is that table looks different in Firefox and IE. Here is an example:
http://www.freeimagehosting.net/image.php?224860e266.png
Here is the table code in ASP.NET:
<table align="center" cellpadding="0" cellspacing="1" style="text-align: right; border-collapse: separate;">
<tr>
<td>
Nadawca:
</td>
<td>
<asp:TextBox ID="TextBoxNadawca" runat="server" Width="250px" BorderStyle="none"
BackColor="#c1ae85"></asp:TextBox>
</td>
<td align="left">
<asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ErrorMessage="Nadawca jest wymagany."
ControlToValidate="TextBoxNadawca" ForeColor="Red"></asp:RequiredFieldValidator>
</td>
</tr>
<tr>
<td>
Adres e-mail:
</td>
<td>
<asp:TextBox ID="TextBoxMail" runat="server" Width="250px" BorderStyle="none" BackColor="#c1ae85"></asp:TextBox>
</td>
<td align="left">
<asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ErrorMessage="E-mail jest wymagany."
ControlToValidate="TextBoxMail" ForeColor="Red"></asp:RequiredFieldValidator>
<asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" ControlToValidate="TextBoxMail"
ErrorMessage="Nieprawidłowy format." ForeColor="Red" Style="position: absolute;
top: 589px; left: 632px; width: 160px;" ValidationExpression="\w+([-+.']\w+)*#\w+([-.]\w+)*\.\w+([-.]\w+)*"></asp:RegularExpressionValidator>
</td>
</tr>
<tr>
<td>
Temat:
</td>
<td>
<asp:DropDownList ID="DropDownTemat" runat="server" Style="margin-left: 0px;" Width="250px"
BorderStyle="none" BackColor="#c1ae85">
<asp:ListItem>Reklama w serwisie</asp:ListItem>
<asp:ListItem>Pomysł na rozwój serwisu</asp:ListItem>
<asp:ListItem>Chcę zostać moderatorem</asp:ListItem>
<asp:ListItem>Prawa autorskie</asp:ListItem>
<asp:ListItem>Banicja</asp:ListItem>
<asp:ListItem>Błąd na stronie</asp:ListItem>
<asp:ListItem>Inne</asp:ListItem>
</asp:DropDownList>
</td>
</tr>
<tr>
<td>
Treść:
</td>
<td>
<asp:TextBox ID="TextBoxTresc" runat="server" Height="150px" TextMode="MultiLine"
Width="250px" BorderStyle="none" BackColor="#c1ae85"></asp:TextBox>
</td>
<td align="left">
<asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ErrorMessage="Treść jest wymagana."
ControlToValidate="TextBoxTresc" ForeColor="Red"></asp:RequiredFieldValidator>
</td>
</tr>
<tr>
<td>
</td>
<td style="text-align: center;">
<asp:Button ID="Button1" runat="server" Text="Wyślij" OnClick="Button1_Click" Width="250px"
BorderStyle="None" BackColor="#c1ae85" />
</td>
</tr>
<tr>
<td>
</td>
<td style="text-align: justify">
<br />
<asp:Label ID="Label1" runat="server" Width="250px"></asp:Label>
</td>
</tr>
</table>
Thanks in advice,
Peter.
When i remove your styling code
<table align="center" cellpadding="0" cellspacing="1" style="text-align: right; border-collapse: separate;">
to
<table align="center">
It shows same for IE, Firefox and Chrome. So if you want to style your table ill suggest you to try CSS
Don't use tables for your layout, use CSS. The only time you should use tables is for tabular data. By using CSS here you can omit border-bottom where you are getting the double borders.

Resources