Tag Archives: Lists

SharePoint Virtual Summit 2017

The 2017 SharePoint virtual summit took place last week. The previous year had seen a brave new bold redesign of SharePoint into a modern experience. This year we had exciting new announcements building on last year’s vision.

New OneDrive and SharePoint Sync Client

The new version of OneDrive sync client will map out the entire contents of SharePoint and OneDrive libraries without syncing them across. Documents will only be synced when requested on-demand or when a document is opened and edited.

OneDrive Files On Demand

This is great news and solves two problems faced by OneDrive users:

  • Large OneDrive/SharePoint libraries consumed large amounts of local storage syncing across
  • Possibility of errors when large numbers of files synced at once

A new unified sharing interface will be rolled out across OneDrive and SharePoint for a simpler experience. This feature will also be available in windows explorer.

SharePoint Virtual Summit

Communication portals

SharePoint released a new experience team site last year. It has now matured with developers creating third party web parts using the SharePoint Framework. Microsoft have now released a new type of site called a communication portal. This site replaces the older publishing sites used for company intranets. Although the new site is responsive out-of-the-box, we can now apply custom branding and functionality extending this into a true intranet experience.

SharePoint Communication Portal

Integration with Flow and PowerApps

These two new Office 365 apps are gaining momentum as modern replacements for SharePoint Designer Workflows and InfoPath Forms Designer.

Microsoft Flow creates workflows that can integrate with almost any product including Google Calendar, Twitter, Slack and a whole host of other services. Flow will have tighter integration with SharePoint and Flows can be created directly from list views.

PowerApps empowers users to create useful mobile friendly apps with no code for SharePoint and OneDrive. This has now been extended to integrate directly into a SharePoint page. PowerApps can now act as the custom form for SharePoint list data. This was a task previously done using InfoPath Designer or custom code.

SharePoint with PowerApps and Microsoft Flow

There was also news of a more powerful personalised search and much more. You can read the Microsoft review from Jeff Teper here.

So, it’s another exciting year ahead for the SharePoint and Office community!

Set default classic or new experience in SharePoint Online

The new list and library experience is here in SharePoint Online. It is great news for the SharePoint community (better integration with OneDrive, responsive, platform independent). For users with customisations or for companies who are not ready for the change yet, you can delay the new experience from the administration panel. There are certainly things which will improve in the new experience such as consistent navigation (you may notice that you lose the navigation configured in classic mode), custom JS overlays and custom branding. Microsoft should have some updates on those features in the coming year.

To switch back to classic mode for the entire tenancy:

Open the Office 365 admin centre and select “SharePoint” from the admin centre list.

Office 365 admin area

Go to the settings option and set the list and library view to classic mode. This may take a few moments to apply.

Office 365 admin area

You can override these settings in individual library settings if required.

Styling SharePoint 2010 Lists using XSL

XSL (EXtensible Stylesheet Language) styles the XML output of SharePoint 2010 lists. It allows easy customisation without any server side code.

For example, this is a standard Tasks Web Part.

SharePoint 2010 Task List

After having an XSL stylesheet applied, it transforms the way the list is rendered (see below).

XSL Task List

In the example below, the template is called for each item depending what the “Status” field contains.

<xsl:for-each select="dsQueryResponse/Rows/Row[contains(@Status, 'In Progress') or contains(@Status, 'Not Started') or contains(@Status, 'Waiting on someone else')]" >
        <xsl:sort select="@Created" order="descending"/>
        <xsl:call-template name="row"/>
      </xsl:for-each>

If the status is “In Progress”, “Not Started” or “Waiting on someone else”, the template named “row” is called. Each item is sorted by the Creation date.

In the row template, the image src attribute (location of traffic light colour image) is selected using an if statement on the status field. For each status a different image is displayed.

<img>
				<xsl:attribute name="src">	
					<xsl:if test="@Status = 'Completed'">
						/Style%20Library/XSLT/green.png
					</xsl:if>
					<xsl:if test="@Status = 'In Progress'">
						Style%20Library/XSLT/amber.png
					</xsl:if>
					<xsl:if test="@Status = 'Not Started'">
						/Style%20Library/XSLT/red.png
					</xsl:if>
					<xsl:if test="@Status = 'Deferred'">
						/Style%20Library/XSLT/grey.png
					</xsl:if>
					<xsl:if test="@Status = 'Waiting on someone else'">
						/Style%20Library/XSLT/grey.png
					</xsl:if>
				</xsl:attribute>
			</img>

The complete code below with some CSS applied generates the customised Tasks list view.


<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:msxsl="urn:schemas-microsoft-com:xslt" >
  <xsl:output method="xml" indent="yes"/>
  <xsl:template match="/">
    <div style="padding: 5px 8px 5px 5px; display:block;">
      <span class="tasksGroups">My Current Tasks:</span>
      <xsl:for-each select="dsQueryResponse/Rows/Row[contains(@Status, 'In Progress') or contains(@Status, 'Not Started') or contains(@Status, 'Waiting on someone else')]" >
        <xsl:sort select="@Created" order="descending"/>
        <xsl:call-template name="row"/>
      </xsl:for-each>
    </div>
    <div style="padding: 0px 8px 0px 0px; display:block;">
     <span class="tasksGroups"> My Completed Tasks:</span>
      <xsl:for-each select="dsQueryResponse/Rows/Row[contains(@Status, 'Deferred') or contains(@Status, 'Completed')]" >
        <xsl:sort select="@Created" order="descending"/>
        <xsl:call-template name="row"/>
      </xsl:for-each>
    </div>


  </xsl:template>
  <xsl:template name="row" match="dsQueryResponse/Rows/Row">
	<div class="TaskBox">
		<div id="infoleft">
			<img>
				<xsl:attribute name="src">	
					<xsl:if test="@Status = 'Completed'">
						/Style%20Library/XSLT/green.png
					</xsl:if>
					<xsl:if test="@Status = 'In Progress'">
						Style%20Library/XSLT/amber.png
					</xsl:if>
					<xsl:if test="@Status = 'Not Started'">
						/Style%20Library/XSLT/red.png
					</xsl:if>
					<xsl:if test="@Status = 'Deferred'">
						/Style%20Library/XSLT/grey.png
					</xsl:if>
					<xsl:if test="@Status = 'Waiting on someone else'">
						/Style%20Library/XSLT/grey.png
					</xsl:if>
				</xsl:attribute>
			</img>
			<xsl:value-of select="@Status" />
		</div>
		<div id="infomiddle">
			<span id="core-tasks-title"><xsl:value-of select="@Title" /></span><br />
			<span id="core-tasks-body"><xsl:value-of select="@Body" disable-output-escaping="yes"/></span><br />
		</div>
		<div id="inforight"><xsl:value-of select="@PercentComplete" />
		</div>
		<br style="clear:both" />
	</div>
  </xsl:template>
</xsl:stylesheet>

Using XSL and CSS provides a large opportunity to customise SharePoint frontend design of lists without any custom solutions or server side code. This technology will become more important as users move to hosted SharePoint solutions like Office 365 with limited access to server side customisation. It also allows for easier upgrades to future versions of SharePoint.