CardView.FocusedCardTopFieldIndex Property
Gets or sets the index of the top visible field within the focused card.
Namespace: DevExpress.XtraGrid.Views.Card
Assembly: DevExpress.XtraGrid.v24.2.dll
Declaration
[Browsable(false)]
[DefaultValue(0)]
public virtual int FocusedCardTopFieldIndex { get; set; }
Property Value
Type | Default | Description |
---|---|---|
Int32 | 0 | An integer value specifying the zero-based index of the focused card’s top visible field. |
Remarks
If cards do not fit into the View vertically, their contents are only partially displayed . Unfocused cards always display their top fields in such a case. The focused card can be scrolled via code using the FocusedCardTopFieldIndex property. Assigning a value to this property results in scrolling the card vertically so that the field with the specified index becomes the top visible (if possible). Assigning negative values results in scrolling the card to the top. Assigning values greater than the last available index, scrolls the card to the last field.
Note: the FocusedCardTopFieldIndex property specifies the field by its visible index (the GridColumn.VisibleIndex property value).
End-users can also scroll cards. Card scroll buttons serve for this purpose. The availability of these buttons is controlled by the View’s CardView.VertScrollVisibility property.
Note
Detail pattern Views do not contain data and they are never displayed within XtraGrid. So, the FocusedCardTopFieldIndex member must not be invoked for these Views. The FocusedCardTopFieldIndex member can only be used with Views that display real data within the Grid Control. Use the following methods to access these Views with which an end user interacts at runtime.
- GridControl.MainView - returns the top most View in a grid;
- GridControl.FocusedView - returns the focused View;
- GridControl.DefaultView - returns the currently maximized View;
- the sender parameter of View specific events;
- GridView.GetDetailView - returns a detail clone View for a specific master row.