ListObject.Publish method (Excel)
Publishes the ListObject object to a server that is running Microsoft SharePoint Foundation.
Syntax
expression.Publish (Target, LinkSource)
expression A variable that represents a ListObject object.
Parameters
Name | Required/Optional | Data type | Description |
---|---|---|---|
Target | Required | Variant | Contains an array of String values, as described in the Remarks section. |
LinkSource | Required | Boolean | See the Remarks section. |
Return value
A String value that represents the URL of the published list on the SharePoint site.
Remarks
The Target parameter contains an array of String elements, as described in the following table.
Element # | Contents |
---|---|
0 | URL of SharePoint server |
1 | ListName (Display Name) |
2 | Description of the list. Optional. |
If the ListObject object is not currently linked to a list on a SharePoint site, setting LinkSource to True creates a new list on the specified SharePoint site.
If the ListObject object is currently linked to a list on a SharePoint site, setting LinkSource to True replaces the existing link (you can only link the list to one SharePoint site).
If the ListObject object is not currently linked, setting LinkSource to False leaves the ListObject object unlinked.
If the ListObject object is currently linked to a SharePoint site, setting LinkSource to False keeps the ListObject object linked to the current SharePoint site.
Support and feedback
Have questions or feedback about Office VBA or this documentation? Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.