Hide
Writing an article is easy - try our reStructured Text demo Join Siafoo Now or Learn More

Tasks (List Data) using SharePoint Data Zoom Web Part Atom Feed 0

In Brief Displays a list of tasks and provides a link on the tasks title to the SharePoint Edit page.
# 's
 1## Get the tasks list
2#set( $tasksList = $web.lists.get_item("Tasks") )
3
4## Get edit url information
5#set( $sourceUrlEncoded = $HttpUtility.UrlEncode($request.RawUrl) )
6#set( $editForm = $tasksList.Forms.get_item($PAGETYPE_PAGE_EDITFORM) )
7
8#foreach($item in $tasksList.Items)
9 #beforeall
10 <table class="ms-listviewtable" cellpadding="3" cellspacing="0" border="0" width="100%">
11 <tr class="ms-viewheadertr">
12 <th class="ms-vh2-nofilter">Title</th>
13 <th class="ms-vh2-nofilter">Created</th>
14 <th class="ms-vh2-nofilter">Modified</th>
15 </tr>
16 #odd
17 <tr class="">
18 #even
19 <tr class="ms-alternating">
20 #each
21 <td class="ms-vb2"><a href="$web.Url/$editForm.Url?ID=$item.ID&Source=$sourceUrlEncoded">$item.Title</a></td>
22 <td class="ms-vb2">$item.get_item("Created").ToString("d")</td>
23 <td class="ms-vb2">$item.get_item("Modified").ToString("d")</td>
24 #after
25 </tr>
26 #afterall
27 </table>
28 #nodata
29 No tasks found
30
31#end

Displays a list of tasks and provides a link on the tasks title to the SharePoint Edit page.