SPListTemplate class
代表清單定義或定義的欄位和清單檢視的清單範本。清單定義包含在檔案內%ProgramFiles%\Common Files\Microsoft Shared\web server extensions\15\TEMPLATE\FEATURES,但清單範本時,會建立透過使用者介面或物件模型清單儲存成範本。
Inheritance hierarchy
System.Object
Microsoft.SharePoint.SPListTemplate
Namespace: Microsoft.SharePoint
Assembly: Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Syntax
'宣告
Public Class SPListTemplate
'用途
Dim instance As SPListTemplate
public class SPListTemplate
備註
您可以使用SPWeb類別的ListTemplates屬性,傳回SPListTemplateCollection物件,表示 Web 站台的清單定義的集合。使用SPSite類別的GetCustomListTemplates方法,傳回SPListTemplateCollection物件,表示網站集合的清單範本集合。若要從集合傳回單一清單定義或清單範本中使用索引子。例如,如果集合指派給一個名為myListTemplates變數,請在 Microsoft Visual C#,或myListTemplates(index) 在 Microsoft Visual Basic,其中index是定義或範本集合中的索引編號或定義或範本的名稱中使用myListTemplates[index]。
Thread safety
Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.