Lists.DeleteList method
會刪除指定的清單。
Namespace: WebSvcLists
Assembly: STSSOAP (in STSSOAP.dll)
Syntax
'宣告
<SoapDocumentMethodAttribute("https://schemas.microsoft.com/sharepoint/soap/DeleteList", RequestNamespace := "https://schemas.microsoft.com/sharepoint/soap/", _
ResponseNamespace := "https://schemas.microsoft.com/sharepoint/soap/", _
Use := SoapBindingUse.Literal, ParameterStyle := SoapParameterStyle.Wrapped)> _
Public Sub DeleteList ( _
listName As String _
)
'用途
Dim instance As Lists
Dim listName As String
instance.DeleteList(listName)
[SoapDocumentMethodAttribute("https://schemas.microsoft.com/sharepoint/soap/DeleteList", RequestNamespace = "https://schemas.microsoft.com/sharepoint/soap/",
ResponseNamespace = "https://schemas.microsoft.com/sharepoint/soap/",
Use = SoapBindingUse.Literal, ParameterStyle = SoapParameterStyle.Wrapped)]
public void DeleteList(
string listName
)
參數
listName
Type: System.String字串,包含標題或清單的 GUID。
Examples
下列程式碼範例會從目前網站中刪除指定的清單。
Dim listService As New Web_Reference_Folder.Lists()
listService.Credentials = System.Net.CredentialCache.DefaultCredentials
listService.DeleteList("List_Name")
Web_Reference_Folder.Lists listService = new Web_Reference_Folder.Lists();
listService.Credentials= System.Net.CredentialCache.DefaultCredentials;
listService.DeleteList("List_Name");