Click here to Skip to main content
15,740,731 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:

I used Radiobutton list in my page

<asp:RadioButtonList ID="rblDirections" runat="server" RepeatDirection="Horizontal">         <asp:ListItem Text="East" Value="East"><asp:ListItem Text="West" Value="West"><asp:ListItem Text="North" Value="North"><asp:ListItem Text="South" Value="South"> 

I want text of each itemlist be at the right of radiobutton

here text are at the left .

how i can do it?

thanks alot
Updated 25-Dec-12 21:45pm
Sergey Alexandrovich Kryukov 26-Dec-12 3:31am    
Why? Is it for right-to-left writing systems? Otherwise, unusual location of text will only confuse the users...
[no name] 26-Dec-12 3:52am    
Do you want to show the radio buttons in the left and the text are at the right of the radio buttons or The text are in the left and the radio buttons in the right of the text?

If you want to change the place where the text should be displayed (either left or right) of the radio button. You can use text align Property of asp:RadioButtonList.

Change it from Left or Right.

<asp:radiobuttonlist id="rblDirections" xmlns:asp="#unknown">
runat="server" RepeatDirection="Vertical" 
                <asp:listitem text="East" value="East" />
                    <asp:listitem text="West" value="West" />
                        <asp:listitem text="North" value="North" />
                            <asp:listitem text="South" value="South" />

Hope this Helps.
Share this answer
set textalign property
Share this answer
use TextAlign properties of radiobuttonlist control
Share this answer
use TextAlign properties of radiobuttonlist control
Share this answer

use like this
<asp:RadioButtonList ID="rblDirections" runat="server" RepeatDirection="Horizontal" TextAlign="Left">
<asp:ListItem Text="East" Value="East"></asp:ListItem>
<asp:ListItem Text="West" Value="West"></asp:ListItem>
<asp:ListItem Text="North" Value="North"></asp:ListItem>
<asp:ListItem Text="South" Value="South">

Share this answer

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900