A
Andy Fish
Hi,
In a repeater control I had something like this:
<a id="lnk_Lookup" href='lookup.aspx?userid=<%#DataBinder.Eval(Container,
"DataItem.UserId")%>'>go</a>
This works fine and the href is generated correctly. However, I also want to
process the control in the codebehind file, so I added a "runat=server"
attribute. Now the URL is not substituted by the databinder so it remains
the literal string as seen in the source for the page.
I have also tried changing it to an <asp:hyperlink> but still the same
result.
Any ideas what is happening here?
TIA
Andy
In a repeater control I had something like this:
<a id="lnk_Lookup" href='lookup.aspx?userid=<%#DataBinder.Eval(Container,
"DataItem.UserId")%>'>go</a>
This works fine and the href is generated correctly. However, I also want to
process the control in the codebehind file, so I added a "runat=server"
attribute. Now the URL is not substituted by the databinder so it remains
the literal string as seen in the source for the page.
I have also tried changing it to an <asp:hyperlink> but still the same
result.
Any ideas what is happening here?
TIA
Andy