Hello,
Your code is ok, but it needs to be included as a part of transformation, so please take it:
<div><%# DataRowView.DataView.Count %>
<a href="<%# Eval("NodeAliasPath") %>.aspx">
<img src="<%# Eval("NewsTeaser","/getattachment/{0}/img.aspx?") %>" width="100px" height="100px" alt=""/></a>
<div>
<a href="<%# Eval("NodeAliasPath") %>.aspx"><h3><%# Eval("NewsTitle")%></h3></a>
<br />
<%# Eval("NewsSummary") %>
</div>
</div>
and place it to a new transformation in the
Site Manager -> Development -> Document types -> News -> Transformation section and name it as "my_trans" and update your repeater code to contain the name of your transformation:
<cms:CMSRepeater runat="server" ID="cmsRptListNews" Path="/News/%" TransformationName="CMS.News.my_trans" ClassNames="CMS.News" OrderBy="NewsID DESC" EnableViewState="false" EnablePaging="True" PageSize="5" PagerControl-PagerPosition="Bottom">
</cms:CMSRepeater>
Best regards,
Jan Hermann