Spread ASP.NET 14
FarPoint.Web.Spread Assembly / FarPoint.Web.Spread Namespace / SheetView Class / LoadOnDemandMode Property

In This Topic
    LoadOnDemandMode Property
    In This Topic
    Gets or sets the LoadOnDemandMode property. In Standard mode, spread loads the next set of rows, if after scrolling, there are no bottom rows (in the view) that are hidden. In Background mode, spread loads the next set of rows after a period of time or after the user scrolls to the row at the LoadOffsetFromBottom position.
    Public Property LoadOnDemandMode As LoadOnDemandMode
    Dim instance As SheetView
    Dim value As LoadOnDemandMode
    instance.LoadOnDemandMode = value
    value = instance.LoadOnDemandMode
    public LoadOnDemandMode LoadOnDemandMode {get; set;}
    This example sets the LoadOnDemandMode 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.Sheets[0].LoadOnDemandMode = FarPoint.Web.Spread.LoadOnDemandMode.Background;
    FpSpread1.Sheets[0].LoadOnDemandTriggerMode = FarPoint.Web.Spread.LoadOnDemandTriggerMode.Timed;
    FpSpread1.Sheets[0].LoadOnDemandInterval = 1000; // after every second, perform load on demand 
    FpSpread1.Sheets[0].LoadOffsetFromBottom = 20; // this setting is meaningless in Timed 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.Sheets(0).LoadOnDemandMode = FarPoint.Web.Spread.LoadOnDemandMode.Background
    FpSpread1.Sheets(0).LoadOnDemandTriggerMode = FarPoint.Web.Spread.LoadOnDemandTriggerMode.Timed
    FpSpread1.Sheets(0).LoadOnDemandInterval = 1000 ' after every second, perform load on demand 
    FpSpread1.Sheets(0).LoadOffsetFromBottom = 20 ' this setting is meaningless in Timed trigger mode 
    End Sub
    See Also