Is it possible to put a RadButton inside a bound DataList?
I have a dataset with two columns returned (bound in the code-behind). First column is called HowFoundDesc (a description), and second is FoundThisWay (a Boolean). I can bind the HowFoundDesc to the Text attribute of the DataList, but I don't know how to bind the FoundThisWay Boolean flag to the RadButton so as to toggle the state of the button (it is a toggle radio button with images).
When I run it, I get the descriptions fine for each, but all the images are defaulting to the off value. Also, when I click on the buttons, they are all acting separate instead of a group, even though I have the groupname defined in the RadButton.
Any ideas?
<div Style="font-size: 14px; top: 4px; left: 5px; position: absolute;"> <asp:DataList ID="HowFound" runat="server" RepeatDirection="Horizontal" RepeatColumns="5" > <ItemTemplate> <telerik:RadButton ID="rbHowFound" runat="server" ForeColor="Blue" AutoPostBack="false" ButtonType="ToggleButton" GroupName="grpHowFound" ToggleType="Radio" Text=<%# Eval("HowFoundDesc")%> > <ToggleStates> <telerik:RadButtonToggleState PrimaryIconCssClass="rbRemove" /> <telerik:RadButtonToggleState PrimaryIconCssClass="rbOk" Selected="true" /> </ToggleStates> </telerik:RadButton> </ItemTemplate> </asp:DataList> </div>