Spread Windows Forms 8.0 Product Documentation
Advance Event (FpSpread)
Example 


Occurs when the user tries to advance from the first or last row in Spread.
Syntax
'Declaration
 
Public Event Advance As AdvanceEventHandler
'Usage
 
Dim instance As FpSpread
Dim handler As AdvanceEventHandler
 
AddHandler instance.Advance, handler
public event AdvanceEventHandler Advance
Event Data

The event handler receives an argument of type AdvanceEventArgs containing data related to this event. The following AdvanceEventArgs properties provide information specific to this event.

PropertyDescription
AdvanceNext Gets whether to move to the next component.
Cancel Gets or sets whether to cancel default processing.
Remarks

This event occurs when the user moves the focus to the next or previous component on the form. This event occurs when the user performs one of the following actions:

The application responds by moving the focus to the next or previous component on the form.

This works as long as you have not overridden the default behavior of the Tab key. For more information on defining the Tab key, refer to information on the InputMap and action keys.

This event is raised by the OnAdvance method when the focus is advancing to the next item.

For more details on the individual event arguments, refer to AdvanceEventArgs members.

Example
This example raises the Advance event when the user presses the up arrow key and the focus is in the first row.
private void fpSpread1_Advance(object sender, FarPoint.Win.Spread.AdvanceEventArgs e)
{
     ListBox1.Items.Add("Advance event fired!");
}

Label1.Text = "Click on a cell in the first row and press the UP arrow key."
Private Sub FpSpread1_Advance(ByVal sender As Object, ByVal e As FarPoint.Win.Spread.AdvanceEventArgs) Handles FpSpread1.Advance
     ListBox1.Items.Add("Advance event fired!")
End Sub

Label1.Text = "Click on a cell in the first row and press the UP arrow key."
Requirements

Target Platforms: Windows 2000 Professional (SP4), Windows 2000 Server, Windows 2003 Server (SP1), Windows 2008, Windows XP (SP2), Windows Vista, Windows 7, Windows 8

See Also

Reference

FpSpread Class
FpSpread Members
AdvanceEventArgs Class

 

 


Copyright © GrapeCity, inc. All rights reserved.