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

ASPxCardViewCardLayoutCreatedEventArgs.Properties Property

Contains settings related to the FormLayout used in the processed card.

Namespace: DevExpress.Web

Assembly: DevExpress.Web.v20.2.dll

NuGet Package: DevExpress.Web

Declaration

public FormLayoutProperties Properties { get; }

Property Value

Type Description
FormLayoutProperties

A FormLayoutProperties object that represents settings of the current card’s FormLayout.

Remarks

Example

MVC:

var cardView = Html.DevExpress().CardView(settings =>
{
    settings.Name = "CardView";
    settings.CallbackRouteValues = new { Controller = "Home", Action = "CardViewPartial" };
    settings.KeyFieldName = "ID";

    settings.CardLayoutCreated = (s, e) =>
    {
        var cv = (MVCxCardView)s;
        if (Convert.ToInt32(cv.GetCardValues(e.VisibleIndex, "ID")) == 2)
        {
            e.Properties.ForEach((item) =>
            {
                var cardLayoutItem = item as MVCxCardViewColumnLayoutItem;
                if (cardLayoutItem != null)
                    if (cardLayoutItem.ColumnName == "Test")
                        cardLayoutItem.Visible = false;
            });
        }
    };
});
See Also