M
Mich
Hi,
i made an application where a lot of radiobuttonlists are created
dynamically. Some are visible and others are hidden until the right
selectedvalue is chosen. Thsi works perfectly with IE7, Netscape, Firefox
...., but with IE6, there are big gaps between the radiobuttonlists.
I looked at the source of both browser versions, but there is no difference.
The difference is in the way of rendering the html code.
I suspect that this line of the source: <div style="height:5px"> is
interpreted differently. I tried with height:1px" but there was no
difference in IE6. Only if i commented it the gap was closed. In IE7, this
line creates a little gap between the two radios.
I also noticed that a hidden radiobuttonlist is representd by this line
(with 2 </di> !!)
<div align="left"
style="width:800px;height:0px"> <br></div></div>
Here a sample of the code-behind:
rb(i) = New RadioButtonList
If Session("visible" & vlg) = "n" Then
rb(i).Visible = False
littd(i) = New LiteralControl("<div align=""left""
style=""width:800px;height:0px"">")
Else
littd(i) = New LiteralControl("<div align=""left""
style=""width:800px;background-color:lightsteelblue"">")
End If
frm.Controls.Add(littd(i))
If cond = False Then
lit = New LiteralControl("<div style=""height:5px"">")
frm.Controls.Add(lit)
End If
lit = New LiteralControl("</div>")
frm.Controls.Add(lit)
Thanks for help
Mich
i made an application where a lot of radiobuttonlists are created
dynamically. Some are visible and others are hidden until the right
selectedvalue is chosen. Thsi works perfectly with IE7, Netscape, Firefox
...., but with IE6, there are big gaps between the radiobuttonlists.
I looked at the source of both browser versions, but there is no difference.
The difference is in the way of rendering the html code.
I suspect that this line of the source: <div style="height:5px"> is
interpreted differently. I tried with height:1px" but there was no
difference in IE6. Only if i commented it the gap was closed. In IE7, this
line creates a little gap between the two radios.
I also noticed that a hidden radiobuttonlist is representd by this line
(with 2 </di> !!)
<div align="left"
style="width:800px;height:0px"> <br></div></div>
Here a sample of the code-behind:
rb(i) = New RadioButtonList
If Session("visible" & vlg) = "n" Then
rb(i).Visible = False
littd(i) = New LiteralControl("<div align=""left""
style=""width:800px;height:0px"">")
Else
littd(i) = New LiteralControl("<div align=""left""
style=""width:800px;background-color:lightsteelblue"">")
End If
frm.Controls.Add(littd(i))
If cond = False Then
lit = New LiteralControl("<div style=""height:5px"">")
frm.Controls.Add(lit)
End If
lit = New LiteralControl("</div>")
frm.Controls.Add(lit)
Thanks for help
Mich