getBuildingBlock method

getBuildingBlock(gallery, category, name)

Finds a building block using the specified gallery, category and name.

getBuildingBlock(gallery: Aspose.Words.BuildingBlocks.BuildingBlockGallery, category: string, name: string)
ParameterTypeDescription
galleryBuildingBlockGalleryThe gallery criteria.
categorystringThe category criteria. Can be null, in which case it will not be used for comparison.
namestringThe building block name criteria.

Remarks

This is a convenience method that iterates over all building blocks in this collection and returns the first building block that matches the specified gallery, category and name.

Microsoft Word organizes building blocks into galleries. The galleries are predefined using the BuildingBlockGallery enum. Within each gallery, building blocks can be organized into one or more categories. The category name is a string. Each building block has a name. A building block name is not guaranteed to be unique.

Returns

The matching building block or null if a match was not found.

See Also