Last post Feb 27, 2012 03:17 PM by superguppie
Feb 24, 2012 06:12 PM|HardingR|LINK
I have a GridView which displays hundreds of rows of data. It is very important that I control the height of each row to minimize wasted space. In other words, I want to remove as much white space above and below the text being displayed. This was working
fine until I added a RadioButtonList (with RepeatDirection="Horizontal") to my GridView.
<asp:RadioButtonList ID="optProtest" runat="server" AutoPostBack="true"
<asp:ListItem Text="" Value="M"></asp:ListItem>
<asp:ListItem Text="" Value="U"></asp:ListItem>
<asp:ListItem Text="" Value="B"></asp:ListItem>
Even with Height="8px" the rows' minimum height appears to be around 16px. Is there a way to control the size of the radiobutton image so that I can make it smaller?
Feb 24, 2012 07:26 PM|basheerkal|LINK
Of course, there are Height and Width properties to set..But if the height is less than 16px it will not be visible fully.
Feb 24, 2012 07:35 PM|HardingR|LINK
Setting the Height of the RadioButton to anything less than 16px does not have any affect on the height of the image and the height of the row. Because each radiobutton image appears to be 16px square the minimum height and width appears to be 16px and,
therefore, the minimum height of the row is 16px.
Is there a method of substituting the standard radiobutton image with another smaller image?
Feb 27, 2012 03:17 PM|superguppie|LINK
Haven't tried it, but you could see if this page works: http://ryanfait.com/resources/custom-checkboxes-and-radio-buttons/