Using the sp-list Macro (v 1.1)
You can use the SharePoint List macro {sp-list} to display a SharePoint list on a Confluence wiki page. The macro can display most SharePoint list types.
Screenshot: The SharePoint List macro in Confluence
On this page:
Usage with the Macro Browser
The 'Macro Browser' is a graphical menu that allows you to view the list of available Confluence macros and add them to the current page or blog post.
To insert the SharePoint List macro into a page using the Macro Browser,
Usage with the Wiki Markup Editor
Basic Form
Full Form
Make sure that you enter the entire text on a single line without any line breaks.
{sp-list:SHAREPOINT SITE ALIAS:listName=LIST NAME|columns=COLUMN 1 NAME,COLUMN 1 ALIAS,COLUMN 1 TYPE;COLUMN 2 NAME,COLUMN 2 ALIAS,COLUMN 2 TYPE|debug=TRUE}
Parameters
Separating Multiple Parameters
In wiki markup, the parameters are separated by a pipe character (|). The SharePoint List macro has a slightly more complex format than other Confluence macros. For each parameter, you can enter multiple values separated by a comma (,) or a semi-colon (;). We give a detailed description in the table below.
Parameter | Default | Description |
|---|---|---|
listname | No default | The first parameter can contain either just the name of the SharePoint list ('listName') or the SharePoint site alias and the list name, separated by a colon (:). The text '
{sp-list:documents|document}
In the next example, the first parameter contains an alias '
{sp-list:mySharePoint:documents|document}
Here is another example with alias and list name, where the parameter name '
{sp-list:mySharePoint:listName=documents|document}
Specifying the full path to your listYou must give the full path to the list. In the above example, we have assumed that the list is located at the root (top-level) SharePoint site. However, if the list is in a SharePoint site called '
{sp-list:/SiteDirectory/mySubSite/documents|document}
Displaying the contents of a document folderTo display the contents of a folder '
{sp-list:/SiteDirectory/mySubSite/documents//my folder|document}
|
(Unnamed parameter: List type) | No default | Use this parameter to specify the type of the list in SharePoint. If you do not specify the columns (see below), then you must specify the list type. If you do not specify the columns, Confluence will display default columns for the given list type. The macro supports the following list types:
|
columns | If the 'list type' parameter is present and there is no 'columns' parameter, then SharePoint will display default columns for the given list type. | Use this parameter to specify the columns of the SharePoint list that will be displayed on the Confluence page. If you do not specify the columns, Confluence will display default columns for the given list type. If you specify both the list type and the columns, Confluence will display the specified columns instead of the default columns.
columns=COLUMN 1 NAME,COLUMN 1 ALIAS,COLUMN 1 TYPE;COLUMN 2 NAME,COLUMN 2 ALIAS,COLUMN 2 TYPE
For example:
{sp-list:documents|columns=BaseName,Document Name,doc;FileSizeDisplay,File Size,fileSize;Modified,,date;Author,,author;view}
|
debug | False | Set this parameter to 'true' if you want to send the SharePoint SOAP response to the HTML source of the page. You can see the result by viewing the source of the page. See more below. |