<%
listitem1.Text = commIndexText["tx_3"].ToString(); listitem2.Text =
commIndexText["tx_8"].ToString();
listitem3.Text = commIndexText["tx_9"].ToString();
%>
<asp:RadioButtonList CssClass="smallFont" ID="login_details"
runat="server" TextAlign="right">
<asp:ListItem ID="listitem1" Value=1 ></asp:ListItem>
<asp:ListItem ID="listitem2" Value=2 ></asp:ListItem>
<asp:ListItem ID="listitem3" Value=3 ></asp:ListItem>
</asp:RadioButtonList>
the three .Text lines at the top get text from a database and put it in
place, which works fine
The RadioButtonList specifies the CssClass as "smallFont", which is
Tahoma 8pt, but this isn't applied to the text I add to my ListItems.
Can anyone help me understand why?
TIA
Kevin
"Kevin Blount" <kevin....@LOLgmail.com> wrote in message news:uUU5DP9...@TK2MSFTNGP03.phx.gbl...
listitem1.Text = "<span class='smallFont'>" +
commIndexText["tx_3"].ToString() + "</font>";
It also works on other .NET form controls, such as <asp:TextBox>
> The RadioButtonList specifies the CssClass as "smallFont", which is Tahoma
> 8pt, but this isn't applied to the text I add to my ListItems.
Because the CSS-Class is only for the table generated.
You will need to have CSS-Class for each ListItem that you add... I'm
afraid, there's no other way out (AFAIK).
--
Happy Hacking,
Gaurav Vaish | www.mastergaurav.com
www.edujinionline.com
http://eduzine.edujinionline.com
-----------------------------------------
I think I tried adding the style to the ListItem as well, with no luck.
I'll revert to adding <span class=> when adding the listitem.Text; it's
dirty, but it works :)
Kevin
But my hack as noted above doesn't work for removing colored background the
POS IE applies to checkboxes and radio buttons.
Does anybody know how to get rid of the colored background? This bug showed
up a long long time ago and at one time I had and used the hack to
work-around the POS IE but I've forgotten the hack and don't seem to have a
copy of the hack in my snippets collection.
<%= Clinton Gallagher
NET csgallagher AT metromilwaukee.com
URL http://clintongallagher.metromilwaukee.com/
MAP 43°2'17"N 88°2'37"W : 43°2'17"N 88°2'37"W
"Kevin Blount" <kevin....@LOLgmail.com> wrote in message
news:uUU5DP9...@TK2MSFTNGP03.phx.gbl...
try renaming the attribute to :
cssClass="smallFont"
also make sure the case of the name matches the css file case
"Kevin Blount" <kevin....@LOLgmail.com> wrote in message news:OWyCwuC7...@TK2MSFTNGP04.phx.gbl...