Class RecordNavigationBar
The record navigation bar displays arrow buttons and current record fields.
Inherited Members
Namespace: Syncfusion.Windows.Forms
Assembly: Syncfusion.Shared.Base.dll
Syntax
public class RecordNavigationBar : ArrowButtonBar, IControlToolTipProvider, ICancelModeProvider, ISupportUpdating, IInternalArrowButtonParent, IInternalButtonParent, IThemedControl
Constructors
RecordNavigationBar()
Initializes a new RecordNavigationBar.
Declaration
public RecordNavigationBar()
Fields
components
Declaration
protected IContainer components
Field Value
| Type |
|---|
| System.ComponentModel.IContainer |
Properties
AllArrowButtons
Declaration
protected override InternalButton[] AllArrowButtons { get; }
Property Value
| Type |
|---|
| Syncfusion.Windows.Forms.InternalButton[] |
Overrides
AllowAddNew
Indicates whether adding new records is enabled.
Declaration
public bool AllowAddNew { get; set; }
Property Value
| Type |
|---|
| System.Boolean |
AllowStepIncrease
Indicates whether the step for increasing the record position should be increased when the user holds down the mouse on a record navigation button for a longer period.
Declaration
public bool AllowStepIncrease { get; set; }
Property Value
| Type |
|---|
| System.Boolean |
CurrentRecord
Gets or sets the current record position.
Declaration
public int CurrentRecord { get; set; }
Property Value
| Type |
|---|
| System.Int32 |
Font
Gets or sets the System.Drawing.Font value for the control.
Declaration
public override Font Font { get; set; }
Property Value
| Type |
|---|
| System.Drawing.Font |
Label
Gets or sets the label to be displayed before the record field textbox.
Declaration
public string Label { get; set; }
Property Value
| Type |
|---|
| System.String |
MaxLabel
Gets or sets an optional maximum label (e.g. "of 1000").
Declaration
public string MaxLabel { get; set; }
Property Value
| Type |
|---|
| System.String |
MaxRecord
Gets or sets the maximum record position.
Declaration
public int MaxRecord { get; set; }
Property Value
| Type |
|---|
| System.Int32 |
MinRecord
Gets or sets the minimum record position.
Declaration
public int MinRecord { get; set; }
Property Value
| Type |
|---|
| System.Int32 |
NoArrowButtons
Declaration
protected override InternalButton[] NoArrowButtons { get; }
Property Value
| Type |
|---|
| Syncfusion.Windows.Forms.InternalButton[] |
Overrides
RnbData
Gets or sets IRecordNavigationBarData.
Declaration
public IRecordNavigationBarData RnbData { get; set; }
Property Value
| Type |
|---|
| IRecordNavigationBarData |
SingleArrowButtons
Declaration
protected override InternalButton[] SingleArrowButtons { get; }
Property Value
| Type |
|---|
| Syncfusion.Windows.Forms.InternalButton[] |
Overrides
SizeToFit
Declaration
public bool SizeToFit { get; set; }
Property Value
| Type |
|---|
| System.Boolean |
TextBox
Gets or sets the textbox where users can enter record indexes manually.
Declaration
public RichTextBox TextBox { get; }
Property Value
| Type |
|---|
| System.Windows.Forms.RichTextBox |
Methods
CenterInRect(Rectangle, Size)
Declaration
public static Rectangle CenterInRect(Rectangle rect, Size size)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Drawing.Rectangle | rect | |
| System.Drawing.Size | size |
Returns
| Type |
|---|
| System.Drawing.Rectangle |
Dispose(Boolean)
Declaration
protected override void Dispose(bool disposing)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Boolean | disposing |
Overrides
MoveFirst()
Sets the current record position to first record.
Declaration
public void MoveFirst()
MoveLast()
Sets the current record position to the last record.
Declaration
public void MoveLast()
MoveNext()
Sets the current record position to the next record.
Declaration
public void MoveNext()
MovePrevious()
Sets the current record position to the previous record.
Declaration
public void MovePrevious()
OnCurrentRecordChanged(Int32)
Raises the CurrentRecordChanged event.
Declaration
protected virtual void OnCurrentRecordChanged(int record)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Int32 | record | The new record index. |
OnCurrentRecordChanging(ref Int32)
Raises the CurrentRecordChanging event.
Declaration
protected virtual bool OnCurrentRecordChanging(ref int record)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Int32 | record | The new record index. |
Returns
| Type |
|---|
| System.Boolean |
OnEnabledChanged(EventArgs)
Declaration
protected override void OnEnabledChanged(EventArgs e)
Parameters
| Type | Name | Description |
|---|---|---|
| System.EventArgs | e |
OnLayout(LayoutEventArgs)
Declaration
protected override void OnLayout(LayoutEventArgs levent)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.LayoutEventArgs | levent |
Overrides
OnMouseDown(MouseEventArgs)
Declaration
protected override void OnMouseDown(MouseEventArgs mevent)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.MouseEventArgs | mevent |
Overrides
OnMouseUp(MouseEventArgs)
Declaration
protected override void OnMouseUp(MouseEventArgs mevent)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.MouseEventArgs | mevent |
Overrides
OnPaint(PaintEventArgs)
Declaration
protected override void OnPaint(PaintEventArgs pe)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.PaintEventArgs | pe |
Overrides
ProcessKeyPreview(ref Message)
Declaration
protected override bool ProcessKeyPreview(ref Message m)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.Message | m |
Returns
| Type |
|---|
| System.Boolean |
RaiseCurrentRecordChangedEvent(CurrentRecordEventArgs)
Declaration
protected void RaiseCurrentRecordChangedEvent(CurrentRecordEventArgs e)
Parameters
| Type | Name | Description |
|---|---|---|
| CurrentRecordEventArgs | e |
RaiseCurrentRecordChangingEvent(CurrentRecordEventArgs)
Declaration
protected void RaiseCurrentRecordChangingEvent(CurrentRecordEventArgs e)
Parameters
| Type | Name | Description |
|---|---|---|
| CurrentRecordEventArgs | e |
Refresh()
Forces the control to invalidate its client area and immediately redraw itself and any child controls.
Declaration
public override void Refresh()
Overrides
SetCurrentRecord(Int32, Boolean)
Sets the current record position.
Declaration
public void SetCurrentRecord(int value, bool force)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Int32 | value | The new record index. |
| System.Boolean | force | Indicates whether record should be applied to text box even if CurrentRecord is not changed. |
SetCurrentRecord(Int32, Boolean, Boolean)
Sets the current record position and lets you specify if CurrentRecordChanging and CurrentRecordChanged events should be raised.
Declaration
public void SetCurrentRecord(int value, bool force, bool raiseChanged)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Int32 | value | The new record index. |
| System.Boolean | force | Indicates whether record should be applied to text box even if CurrentRecord is not changed. |
| System.Boolean | raiseChanged | Specifies if CurrentRecordChanging and CurrentRecordChanged events should be raised. |
SetValues(Int32, Int32, String, Boolean, Int32)
Thread safe method that applies all settings at once.
Declaration
public void SetValues(int min, int max, string label, bool allowAdd, int current)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Int32 | min | The minimum record position. |
| System.Int32 | max | The maximum record position. |
| System.String | label | The label to be displayed before the record field text box. |
| System.Boolean | allowAdd | Indicates whether adding new records is enabled. |
| System.Int32 | current | The current record position. |
ShowTextBox(Boolean)
Initializes the record field textbox.
Declaration
protected virtual void ShowTextBox(bool setFocus)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Boolean | setFocus | True if focus should be set to the textbox. |
Events
CurrentRecordChanged
Occurs when the current record is changed.
Declaration
public event CurrentRecordChangedEventHandler CurrentRecordChanged
Event Type
| Type |
|---|
| CurrentRecordChangedEventHandler |
CurrentRecordChanging
Occurs when the current record is changing.
Declaration
public event CurrentRecordChangedEventHandler CurrentRecordChanging
Event Type
| Type |
|---|
| CurrentRecordChangedEventHandler |