I am following a course that I had previously taken to refresh my memory. I have an issue with C#. The lesson say's to use is this code in a Repeater:
Here is the error message.
Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.
Compiler Error Message: CS0019: Operator '&' cannot be applied to operands of type 'string' and 'method group'
I tried replacing the & with + and got the same thing. Any help on this?
C#:
<ItemTemplate>
<a id="A1" href=<%#"~/MemberPages/viewprofile.aspx?UserId=" & Eval("UserId").ToString %> runat="server" >
<%#Eval("UserName")%></a><br />
</ItemTemplate>
Here is the error message.
Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.
Compiler Error Message: CS0019: Operator '&' cannot be applied to operands of type 'string' and 'method group'
I tried replacing the & with + and got the same thing. Any help on this?