Back to Devexpress

ASPxCardView.SettingsBehavior Property

aspnet-devexpress-dot-web-dot-aspxcardview-32221494.md

latest2.0 KB
Original Source

ASPxCardView.SettingsBehavior Property

Provides access to the CardView’s behavior settings.

Namespace : DevExpress.Web

Assembly : DevExpress.Web.v25.2.dll

NuGet Package : DevExpress.Web

Declaration

csharp
public ASPxCardViewBehaviorSettings SettingsBehavior { get; }
vb
Public ReadOnly Property SettingsBehavior As ASPxCardViewBehaviorSettings

Property Value

TypeDescription
ASPxCardViewBehaviorSettings

An ASPxCardViewBehaviorSettings object that contains the control’s behavior settings.

|

Example

The following example creates and initializes an ASPxCardView at runtime.

csharp
protected void Page_Load(object sender, EventArgs e)
{
    ASPxCardView cv1 = new ASPxCardView();
    cv1.ID = "ASPxCardView1";
    cv1.KeyFieldName = "ProductID";
    Page.Form.Controls.Add(cv1);
    cv1.SettingsBehavior.AllowFocusedCard = true;
    cv1.DataSourceID = "SqlDataSource1";
    cv1.DataBind();
}
aspx
<asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="Provider=Microsoft.Jet.OLEDB.4.0;
    Data Source=|DataDirectory|\nwind.mdb;Persist Security Info=True" ProviderName="System.Data.OleDb" 
    SelectCommand="SELECT [ProductID], [ProductName], [UnitPrice] FROM [Products]">
</asp:SqlDataSource>

See Also

SettingsEditing

Card View

ASPxCardView Class

ASPxCardView Members

DevExpress.Web Namespace