Spread for ASP.NET 10 Product Documentation
LoadOnDemandTriggerMode Property
Example 


Gets or sets the LoadOnDemandTriggerMode property. If trigger mode is Timed, spread loads the next set of rows after a period of time until there are no rows to load. If trigger mode is OffsetBased, spread only loads the next set of rows if the user scrolls to the row at the LoadOffsetFromBottom position.
Syntax
'Declaration
 
Public Property LoadOnDemandTriggerMode As LoadOnDemandTriggerMode
'Usage
 
Dim instance As SheetView
Dim value As LoadOnDemandTriggerMode
 
instance.LoadOnDemandTriggerMode = value
 
value = instance.LoadOnDemandTriggerMode
public LoadOnDemandTriggerMode LoadOnDemandTriggerMode {get; set;}
Example
This example sets the LoadOnDemandTriggerMode property.
protected void Page_Load(object sender, System.EventArgs e)
{
FpSpread1.ActiveSheetView.RowCount = 100;
FpSpread1.ActiveSheetView.PageSize = 200;
FpSpread1.ActiveSheetView.AllowPage = false;

FpSpread1.AllowLoadOnDemand = true;
FpSpread1.LoadInitRowCount = 50;
FpSpread1.LoadRowIncrement = 15;
FpSpread1.ActiveSheetView.LoadOnDemandMode = FarPoint.Web.Spread.LoadOnDemandMode.Background;
FpSpread1.ActiveSheetView.LoadOnDemandTriggerMode = FarPoint.Web.Spread.LoadOnDemandTriggerMode.OffsetBased;
FpSpread1.ActiveSheetView.LoadOffsetFromBottom = 20;
FpSpread1.ActiveSheetView.LoadOnDemandInterval = 1000; // this setting is meaningless in OffsetBased trigger mode
}
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
FpSpread1.ActiveSheetView.RowCount = 100
FpSpread1.ActiveSheetView.PageSize = 200
FpSpread1.ActiveSheetView.AllowPage = False

FpSpread1.AllowLoadOnDemand = True
FpSpread1.LoadInitRowCount = 50
FpSpread1.LoadRowIncrement = 15
FpSpread1.ActiveSheetView.LoadOnDemandMode = FarPoint.Web.Spread.LoadOnDemandMode.Background
FpSpread1.ActiveSheetView.LoadOnDemandTriggerMode = FarPoint.Web.Spread.LoadOnDemandTriggerMode.OffsetBased
FpSpread1.ActiveSheetView.LoadOffsetFromBottom = 20
FpSpread1.ActiveSheetView.LoadOnDemandInterval = 1000 ' this setting is meaningless in OffsetBased trigger mode
End Sub
Requirements

Target Platforms: Windows 7, Windows 8, Windows 10, Windows Vista, Windows Server 2003, Windows Server 2008, Windows Server 2012, Windows XP Professional

See Also

Reference

SheetView Class
SheetView Members

 

 


Copyright © GrapeCity, inc. All rights reserved.