This documentation is archived and is not being maintained.

CatalogZone::ZoneTemplate Property

Gets or sets a template to contain child controls within a CatalogZone control in page persistence format.

Namespace:  System.Web.UI.WebControls.WebParts
Assembly:  System.Web (in System.Web.dll)

[TemplateInstanceAttribute(TemplateInstance::Single)]
[TemplateContainerAttribute(typeof(CatalogZone))]
[BrowsableAttribute(false)]
[PersistenceModeAttribute(PersistenceMode::InnerProperty)]
public:
virtual property ITemplate^ ZoneTemplate {
	ITemplate^ get ();
	void set (ITemplate^ value);
}
<asp:CatalogZone>
	<ZoneTemplate>ITemplate</ZoneTemplate>
</asp:CatalogZone>

Property Value

Type: System.Web.UI::ITemplate
An ITemplate that acts as a container for child controls in the zone.

The ZoneTemplate property references a template of type ITemplate that is used to contain the CatalogPart controls in the zone. The zone template enables page developers to declare the CatalogPart controls they want to use in persistence format, rather than having to create all the controls programmatically.

The set accessor for the ZoneTemplate property calls the InvalidateCatalogParts method, which forces the collection of CatalogPart controls that are declared in the zone template on the page to be refreshed. This ensures that the collection of controls referenced by the zone remains current whenever a user changes the controls actually declared within the template on the page.

Notes to Inheritors

If you want to create a custom CatalogZone zone, but you plan to create the CatalogPart controls programmatically rather than allowing page developers to declare them, you do not need zone template support, and you can inherit directly from the CatalogZoneBase class.

.NET Framework

Supported in: 4, 3.5, 3.0, 2.0

Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows XP SP2 x64 Edition, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.
Show: