中继器标记:
<asp:Repeater ID="Repeater_sorular" runat="server" OnItemCommand="Repeater_sorular_ItemCommand"
OnItemDataBound="Repeater_sorular_ItemBound">
<HeaderTemplate>
</HeaderTemplate>
<ItemTemplate>
<table>
<tr>
<td>
<rad:RadChart ID="RadChart1" runat="server" DefaultType="Pie" Width="700">
<PlotArea Appearance-FillStyle-FillType="Gradient" Appearance-FillStyle-MainColor="#D90420"
Appearance-FillStyle-SecondColor="#FFAD4A" Appearance-Border-Visible="false">
<EmptySeriesMessage>
<TextBlock Text="Seçilen anket henüz oylanmamıştır.">
<Appearance TextProperties-Font="Tahoma, 10pt, style=Bold">
</Appearance>
</TextBlock>
</EmptySeriesMessage>
</PlotArea>
<ChartTitle>
<TextBlock Appearance-TextProperties-Font="Tahoma">
</TextBlock>
</ChartTitle>
<Appearance ImageQuality="HighQuality" Border-Color="#DFDDDD" TextQuality="ClearTypeGridFit">
</Appearance>
<Series>
<rad:ChartSeries Type="Pie" Appearance-TextAppearance-TextProperties-Color="#FFFFFF"
Appearance-TextAppearance-TextProperties-Font="Tahoma">
</rad:ChartSeries>
</Series>
<Legend Visible="True">
<TextBlock Visible="True">
</TextBlock>
</Legend>
</rad:RadChart>
</td>
<td>
<div style="font-weight: bolder; padding: 5px;">
<%#(((RepeaterItem)Container).ItemIndex+1).ToString() %>.
<%#Eval("Subject")%>
</div>
<asp:BulletedList ID="BulletedList_secenekler" runat="server" DataSource='<%#Eval("Secenekler")%>'
DataTextField="OptionName" DataValueField="OptionId" CssClass="sira_numarali">
</asp:BulletedList>
</td>
</tr>
</table>
</ItemTemplate>
<FooterTemplate>
</FooterTemplate>
</asp:Repeater>
和中继器ItemDataBoundEvent
:
protected void Repeater_sorular_ItemBound(object sender, RepeaterItemEventArgs e)
{
RadChart RadChart1 = (RadChart)e.Item.FindControl("RadChart1");
BulletedList bl = (BulletedList)e.Item.FindControl("BulletedList_secenekler");
}
当我调试它控制返回null。我该如何解决。
谢谢。