Tab

ASPxDataViewBase.ItemStyle Property

Gets the style settings used to paint data items.

Namespace: DevExpress.Web

Assembly: DevExpress.Web.v20.2.dll

Declaration

public DataViewItemStyle ItemStyle { get; }
Public ReadOnly Property ItemStyle As DataViewItemStyle

Property Value

Type Description
DataViewItemStyle

A DataViewItemStyle object that contains style settings.

Examples

The following part of the ASPxDataView - Custom Callback online demo illustrates how to customize the control's items style.

...
<dxdv:aspxdataview id="dvCameras" runat="server" columncount="2" rowperpage="5" Width="100%"
    ClientInstanceName="dvCameras" DataSourceID="AccessDataSource1">
        <ItemStyle Height="50px" >
            <Paddings PaddingTop="5px" PaddingBottom="5px"></Paddings>
        </ItemStyle>
        <ItemTemplate>
            <table cellpadding="0" cellspacing="0">
            <tbody><tr><td valign="top">
            <dxe:ASPxImage id="ModelImage" runat="server" ImageUrl='<%# ImagePath 
                + Eval("ImageFileName") %>'></dxe:ASPxImage>
            </td>
            <td><div style="width: 5px" class="Spacer"></div></td>
            <td>
            <dxe:ASPxLabel id="ModelLabel" runat="server" Text='<%# Eval("Model") %>' 
                Font-Bold="True" CssClass='<%# SortColor("Model") %            >'></dxe:ASPxLabel><br/>
            <dxe:ASPxLabel id="PixelsLabel" runat="server" Text='<%# Eval("Pixels") + " million pixels" %>' 
                CssClass='<%# SortColor("Pixels") %>'></dxe:ASPxLabel>
            </td></tr></tbody>
            </table>
        </ItemTemplate>
</dxdv:aspxdataview>
...
See Also