Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migration of unmigrated content due to installation of a new plugin
Wiki Markup
{introducedin:4.1.0.1379}
{description}
{excerpt}Imports the data from a SharePoint View into a [Table|Table] at the point of the current element in the document. Also accepts a SharePoint List to which the View belongs and a [DataImportProperties|DataImportProperties] object with the import options.{excerpt}
{signature:C#}
public static Table ImportData(this Element element, Microsoft.SharePoint.SPView view, Microsoft.SharePoint.SPList list, DataImportProperties props)
{signature}{signature:vb.net}
Public Shared Function ImportData(ByVal element As Element, ByVal view As Microsoft.SharePoint.SPView, ByVal list As Microsoft.SharePoint.SPList, ByVal props As DataImportProperties) As Table
{signature}
{parameters}
{param:element}The current element which is calling ImportData{param}
{param:view}The SharePoint View to be used as a data source{param}
{param:list}SharePoint List to which the View belongs{param}
{param:props}Import properties for this data import, including max rows, max columns, column filter, etc.{param}
{returns}The {{Table}} into which the data is being imported{returns}
{remarks}
{note}This is an extension method for the Element object to be used for binding SharePoint data to documents from within SharePoint.  To use this method, you must add a reference to SoftArtisans.OfficeWriter.WordWriter.SharePointIntegration.dll{note}
{remarks}
{example}{code:csharp|title=C#}
Table tbl = e.ImportData(myView, myList, importProps);{code}
{code:vb.net|title=vb.net}
Dim tbl As Table = e.ImportData(myView, myList, importProps){code}

{example}