<asp:Repeater ID="rptrParent" runat="server">
<ItemTemplate>
<li>
<a href="<% =ResolveUrl("~/cPanel/UserView.aspx?User=")%><%# Eval("StudentUserName") %>">
<span>
<% ProfileCommon pc = new ProfileCommon();
pc.GetProfile(Eval("StudentUserName").ToString());
Response.Write(pc.FirstName + "" + pc.LastName);
%>
</span>
</a>
</li>
</ItemTemplate>
The following error
Databinding methods such as Eval(), XPath(), and Bind() can only be used in the context of a databound control.
is coming in this part
<% ProfileCommon pc = new ProfileCommon();
pc.GetProfile(Eval("StudentUserName").ToString());
Response.Write(pc.FirstName + "" + pc.LastName);
%>