+1-888-365-2779
Try Now
More in this section

Forums / General Discussions / Trying to calculate the age and years of service right in the Custom Module Template

Trying to calculate the age and years of service right in the Custom Module Template

1 posts, 0 answered
  1. DJ
    DJ avatar
    1 posts
    Registered:
    09 Nov 2010
    05 Feb 2014
    Link to this post
    Forgive me - newbie. I'm tryinjg to calculate the age right within a custom module template. I've tried using eval statements, but can't seen to crack the code. Please help.  The following is the listview in my Custom Module.

    <telerik:RadListView ID="dynamicContentListView" ItemPlaceholderID="ItemsContainer" runat="server" EnableEmbeddedSkins="false" EnableEmbeddedBaseStylesheet="false">
    <LayoutTemplate>
    <ul class="sfitemsList sfitemsListTitleDateTmb">
    <div class="employee-row">
    <asp:PlaceHolder ID="ItemsContainer" runat="server" />
    </div>
    </ul>
    </LayoutTemplate>
    <ItemTemplate>
    <li class="sfitem sfClearfix">
    <div class="employee-info">
    <span class="employee-name">
    <sitefinity:TextField ID="TextName" runat="server" DisplayMode="Read" Value='<%# Eval("Title") %>'></sitefinity:TextField>
    </span>
    <span class="emplyee-age">
    <sitefinity:TextField ID="TextDOB" runat="server" DisplayMode="Read" Value='<%# Eval("DateOfBirth") %>'>
    </sitefinity:TextField>
    <span class="employment-length">(<sitefinity:TextField ID="TextLengthOfEmploy" runat="server" DisplayMode="Read" Value='<%# Eval("StartDate") %>'>
    </sitefinity:TextField>
    )
    </span>
    <div class="employee-location">
    <sitefinity:TextField ID="TextLocation" runat="server" DisplayMode="Read" Value='<%# Eval("Location") %>'>
    </sitefinity:TextField>
    </div>
    <div class="employee-bio clear">
    <p>
    <sitefinity:TextField ID="TextField1" runat="server" DisplayMode="Read" Value='<%# Eval("WorkBio") %>'>
    </sitefinity:TextField>
    </p>
    </div>
    </div>
    <div class="employee-image">
    <sf:ImageAssetsField runat="server" DataFieldName="Photo" IsThumbnail="True" />
    </div>
    </li>
    </ItemTemplate>
    </telerik:RadListView>
    <sf:Pager ID="pager" runat="server"></sf:Pager>
    <asp:PlaceHolder ID="socialOptionsContainer" runat="server"></asp:PlaceHolder>

    Thanks in advance!
1 posts, 0 answered