Skip to main content
A newer version of this page is available. .

Creating Templates

Templates can be created using the Template Designer that is provided by the ASPxCardView control or directly in the .aspx file.

Using the Template Designer

The Template Designer allows you arrange templates. For example, you can drag a Web control from the toolbox onto the template currently being edited.

To invoke the Template Designer, click the Edit Templates task and then select the template. The designer can also be invoked using the ASPxCardView’s context menu. Select the Edit Template menu item and select the template you want to edit. As a result, the ASPxCardView will be displayed in template-editing mode.

ASPxCardView_Design_Templates

When finished, click the End Template Editing task.

Using ASP.NET Syntax

Templates are created as nested tags. To create a template using the ASP.NET syntax, do the following.

  1. In the .aspx file, insert an element inside ASPxCardView (or inside a particular template column) to identify which template you are creating.
  2. Add the template’s contents (HTML text or other Web controls). Include property and data-binding values for the embedded controls using a standard syntax.

    The image below shows how to bind a label to a field.

    ASPxCardView_Templates_Binding

  3. Repeat steps 1 and 2 to create other templates.
See Also