CyberStore Documentation
CatalogItemCharacteristicDisplayControl Class
Members  Example 

Dovetail.Ecommerce.Controls Namespace : CatalogItemCharacteristicDisplayControl Class

A catalog Item Characteristic display control.


The CatalogItemCharacteristicDisplayControl displays all Characteristics from a particular Family.

When you use color as an Item Characteristic, the control displays the value as a color and displays a swatch with that color's common name.

See our topic about the FilterControl for information on the rendering of Characteristic-type colors.

Property Usage

By changing the values of the control's properties in the SitePages.config file for your Site, you can enable or disable certain behaviors, set certain defaults, alter aspects of the display or otherwise cusomtize your site's implementaion of the control.

The following describes properties pertaining to key functional areas of the control that can be configured to suit your needs.

Color Block Properties

There are two color properties for this control which include the ColorBlockHeight property which gets or sets the height of the color block and the ColorBlockWidth property which gets or sets the width of the color block.

Family Name Properties

There are two family name properties for this control which include the DisplayFamilyName property which gets or sets a value indicating whether to display family name and the FamilyName property which gets or sets the name of the family.

General Properties

To hide the control when it is empty the HideOnEmpty property needs to be set to "true" (default). In order to define which window links open to you can edit the LinkWindowName property. When blank values are present in this control they are not displayed. To show blanks in this control you must change the default value of the ShowBlanks property from "false" to "true". The SKUSelectionFields  property is responsible for getting the appropriate SKU selection fields.

Properties Inherited from the Base CyberStoreBaseControl

Properties specific to the CyberStoreBaseControl can be listed in the following categories:

Override Properties

When the IgnoreControl property is set to true, all processing of a control is skipped, and the control's Visible property is set to false ensuring that it is not rendered in the resulting CyberStore page.

Contextual Properties

Contextual properties define specific details about the current instance of the control based on context. Context can be set by any number of factors including the log in state of the Shopper, the Site being visited, or the properties that have been established for a control.

The AttributesBag property is used internal to control processing and is the collection of attributes, or properties, and their values based on how the control is configured. The attributes in this property are set by processing the SitePages.config file as well as any specific declared property values in any registered sub controls. It allows for the passing down of all properties to a control and any registered sub controls.

The ComConfigUserData and Site_ID properties are read-only values made available to all CyberStore controls to aid in processing and establishing context about the Site and Shopper.

See an example of how to configure this control in SitePages.config.
<Control src="CatalogItemCharacteristicDisplayControl.ascx"
       HideOnEmpty="true" />
Control Markup

The following is the markup for this control.

Developer's Note:

To create a custom version of the control, copy all of the code below into a file of the same name and place it into your Site's control folder (e.g., ../YourSiteFolder/Control). The CyberStore page engine will then override the default markup with your customized version.


<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="CatalogItemCharacteristicDisplayControl.ascx.cs"
    Inherits="Dovetail.Ecommerce.Controls.CatalogItemCharacteristicDisplayControl" %>
    <asp:Label ID="lblHeadline" runat="server" Text="" CssClass="CatalogItemCharacteristicHeadline"></asp:Label>
<asp:Repeater ID="rptMain" runat="server">
        <table class="CatalogItemCharacteristicDisplayTable">
            <td class="CharacteristicName">
                <%# Eval("Name") %>
            <td class="CharacteristicValue">
                <%# Eval("Value") %>
                <span class="CharacteristicSuffix">
                    <%# Eval("Suffix") %>
        <tr class="CatalogItemCharacteristicDisplayAlternate">
            <td class="CharacteristicName">
                <%# Eval("Name") %>
            <td class="CharacteristicValue">
                <%# Eval("Value") %>
                <span class="CharacteristicSuffix">
                    <%# Eval("Suffix") %>
Inheritance Hierarchy


See Also


CatalogItemCharacteristicDisplayControl Members
Dovetail.Ecommerce.Controls Namespace