为列表内容类型到列表中,添加指定的网站内容类型。
命名空间: WebSvcLists
程序集: STSSOAP(位于 STSSOAP.dll 中)
语法
声明
<SoapDocumentMethodAttribute("https://schemas.microsoft.com/sharepoint/soap/ApplyContentTypeToList", RequestNamespace := "https://schemas.microsoft.com/sharepoint/soap/", _
ResponseNamespace := "https://schemas.microsoft.com/sharepoint/soap/", _
Use := SoapBindingUse.Literal, ParameterStyle := SoapParameterStyle.Wrapped)> _
Public Function ApplyContentTypeToList ( _
webUrl As String, _
contentTypeId As String, _
listName As String _
) As XmlNode
用法
Dim instance As Lists
Dim webUrl As String
Dim contentTypeId As String
Dim listName As String
Dim returnValue As XmlNode
returnValue = instance.ApplyContentTypeToList(webUrl, _
contentTypeId, listName)
[SoapDocumentMethodAttribute("https://schemas.microsoft.com/sharepoint/soap/ApplyContentTypeToList", RequestNamespace = "https://schemas.microsoft.com/sharepoint/soap/",
ResponseNamespace = "https://schemas.microsoft.com/sharepoint/soap/",
Use = SoapBindingUse.Literal, ParameterStyle = SoapParameterStyle.Wrapped)]
public XmlNode ApplyContentTypeToList(
string webUrl,
string contentTypeId,
string listName
)
参数
webUrl
类型:System.String列表所在网站的 URL。
contentTypeId
类型:System.String要添加与列表内容类型列表网站内容类型的内容类型 ID。
listName
类型:System.String列表的名称。
返回值
类型:System.Xml.XmlNode
一个字符串,采用以下格式,指示该方法成功。
<Success xmlns="https://schemas.microsoft.com/sharepoint/soap/"/>