ListTemplates 接口

定义

对象的集合 ListTemplate ,这些对象代表 "项目符号和编号" 对话框中每个选项卡上的七个预定义列表格式。A collection of ListTemplate objects that represent the seven predefined list formats on each tab in the Bullets and Numbering dialog box.

public interface class ListTemplates : System::Collections::IEnumerable
[System.Runtime.InteropServices.Guid("00020990-0000-0000-C000-000000000046")]
public interface ListTemplates : System.Collections.IEnumerable
type ListTemplates = interface
    interface IEnumerable
Public Interface ListTemplates
Implements IEnumerable
属性
实现

注解

使用 ListTemplates 属性返回ListTemplates集合。Use the ListTemplates property to return the ListTemplates collection.

使用 Add(Object, Object) 方法将列表模板添加到指定的文档或模板中的集合。Use the Add(Object, Object) method to add a list template to the collection in the specified document or template.

使用ListTemplatesindex )(其中 index 是数字1到7)从列表库中返回单个列表模板。Use ListTemplates(index), where index is a number 1 through 7, to return a single list template from a list gallery.

注意:某些属性和方法( Convert(Object) Add(Object, Object) 例如)不能与从列表库中访问的列表模板一起使用。 Note: Some properties and methods— Convert(Object) and Add(Object, Object), for example— won't work with list templates that are accessed from a list gallery. 您可以修改这些列表模板,但不能改变它们的列表库类型(wdBulletGallerywdNumberGallerywdOutlineNumberGallery)。You can modify these list templates, but you cannot change their list gallery type (wdBulletGallery, wdNumberGallery, or wdOutlineNumberGallery).

若要查看指定的列表模板是否包含 Microsoft Word 中内置的格式,请将该 Modified[Int32] 属性与该对象一起使用 ListGalleryTo see whether the specified list template contains the formatting built into Microsoft Word, use the Modified[Int32] property with the ListGallery object. 若要将格式重置为原始列表格式,请使用 Reset(Int32) ListGallery对象的方法。To reset formatting to the original list format, use the Reset(Int32) method for the ListGallery object.

返回ListTemplate对象后,请使用ListLevelsindex ),其中 index 是从1到9的数字,返回单个 ListLevel 对象。After you have returned a ListTemplate object, use ListLevels(index), where index is a number from 1 through 9, to return a single ListLevel object. 通过ListLevel对象,您可以访问指定的列表级别的所有格式设置属性,例如、、、 AlignmentFont NumberFormat NumberPosition NumberStyleTrailingCharacterWith a ListLevel object, you have access to all the formatting properties for the specified list level, such as Alignment, Font, NumberFormat, NumberPosition, NumberStyle, and TrailingCharacter.

使用 Convert(Object) 方法可将多级别列表模板转换为单级模板。Use the Convert(Object) method to convert a multiple-level list template to a single-level template.

属性

Application

返回一个 Application 代表 Microsoft Word 应用程序的对象。Returns a Application object that represents the Microsoft Word application.

Count

返回指定集合中的项目数。Returns the number of items in the specified collection.

Creator

返回一个 32 位整数,它指示在其中创建指定的对象的应用程序。Returns a 32-bit integer that indicates the application in which the specified object was created.

Item[Object]

返回集合中的单个对象。Returns an individual object in a collection.

Parent

返回一个对象,代表指定对象的父对象。Returns an object that represents the parent object of the specified object.

方法

Add(Object, Object)

返回一个 ListTemplate 对象,表示一个新的列表模板。Returns a ListTemplate object that represents a new list template.

GetEnumerator()

适用于