Version

ViewSettings Property (CardView)

Returns/sets the CardViewSettings object for this CardView.
Syntax
'Declaration
 
Public Property ViewSettings As CardViewSettings
public CardViewSettings ViewSettings {get; set;}
Remarks

CardViewSettings exposes properties that let you control features supported by the CardView. Refer to CardViewSettings object for detailed information on these properties.

Example
The following example code demonstrates how to reference the CardViewSettings using xamDataCards or xamDataPresenter.

Imports Infragistics.Windows.DataPresenter


'xamDataCards
Me.xamDataCards1.ViewSettings.ShouldCollapseEmptyCells = True

'xamDataPresenter
Dim cardView1 As CardView = TryCast(Me.xamDataPresenter1.View, CardView)

If cardView1 IsNot Nothing Then
    cardView1.ShouldCollapseEmptyCells = True
End If
using Infragistics.Windows.DataPresenter;


//xamDataCards
this.xamDataCards1.ViewSettings.ShouldCollapseEmptyCells = true;

//xamDataPresenter
CardView cardView1 = this.xamDataPresenter1.View as CardView;

if(cardView1 != null)
{
    cardView1.ShouldCollapseEmptyCells = true;
}
<!--xamDataCards-->
<igDP:XamDataCards Name="xamDataCards1">
    
<igDP:XamDataCards.ViewSettings>
        
<igDP:CardViewSettings ShouldCollapseEmptyCells="True" />
    
</igDP:XamDataCards.ViewSettings>
</igDP:XamDataCards>

<!--xamDataPresenter-->
<igDP:XamDataPresenter Name="xamDataPresenter1">
    
    
<!--If you do not set the View property, xamDataPresenter automatically uses a GridView object-->
    
<igDP:XamDataPresenter.View>
        
<igDP:CardView>
            
<igDP:CardView.ViewSettings>
                
<igDP:CardViewSettings ShouldCollapseEmptyCells="True"  />
            
</igDP:CardView.ViewSettings>
        
</igDP:CardView>
    
</igDP:XamDataPresenter.View>
</igDP:XamDataPresenter>

Requirements

Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Server 2012, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also