K
Kristoffer Arfvidson
Hi!
How can I access a label that I put inside a headertemplate inside a
repeatercontrol from my codebehind?
Or, can I dynamicly add the content of headertemplate from codebehind?
Because I use the same repeater for different views, and I need to modify
the headertemplate dynamicly, depending of the current selection before...
Heres some example code:
-------
<asp:repeater id=Repeater1 runat="server">
<ItemTemplate>
<tr>
<td>
<div align="center">BLABLABLA
<br>
</div>
</td>
</tr>
</ItemTemplate>
<HeaderTemplate>
<tr>
<td>
<b><asp:label id="lblHeadline" Runat="server">SOME TEXT
HERE:</asp:label><br></b>
</td>
</tr>
</HeaderTemplate>
<FooterTemplate>
<tr>
<td>Blablabla
</td>
</tr>
</FooterTemplate>
</asp:repeater>
--------------------
So, now, from the page_load()
HOW?? Do I access the lblHeadline ??
or, How Do I add the context of headerTemplate from Page_Load()
OR, Do I need to use another control?
Yours: Kristoffer
How can I access a label that I put inside a headertemplate inside a
repeatercontrol from my codebehind?
Or, can I dynamicly add the content of headertemplate from codebehind?
Because I use the same repeater for different views, and I need to modify
the headertemplate dynamicly, depending of the current selection before...
Heres some example code:
-------
<asp:repeater id=Repeater1 runat="server">
<ItemTemplate>
<tr>
<td>
<div align="center">BLABLABLA
<br>
</div>
</td>
</tr>
</ItemTemplate>
<HeaderTemplate>
<tr>
<td>
<b><asp:label id="lblHeadline" Runat="server">SOME TEXT
HERE:</asp:label><br></b>
</td>
</tr>
</HeaderTemplate>
<FooterTemplate>
<tr>
<td>Blablabla
</td>
</tr>
</FooterTemplate>
</asp:repeater>
--------------------
So, now, from the page_load()
HOW?? Do I access the lblHeadline ??
or, How Do I add the context of headerTemplate from Page_Load()
OR, Do I need to use another control?
Yours: Kristoffer