# loadNext

## Description

Loads the subsequent records in a dataset after loadData function was run.

## Input / Parameter

| Name            | Description                                   | Input Type  | Default | Options     | Required |
| --------------- | --------------------------------------------- | ----------- | ------- | ----------- | -------- |
| dataset         | The name of the local table to be loaded.     | String/Text | -       | -           | Yes      |
| datasetDisplay? | The values to displayed from the local table. | Boolean     | false   | true, false | No       |

## Output

| Description                                              | Output Type |
| -------------------------------------------------------- | ----------- |
| Returns the list of subsequent records from the dataset. | Array/List  |

## Callback?

### beforeCallback

The function to be executed if the subsequent records are loaded successfully.

## Video

Coming Soon.

## Example

The user wants to load the next of the data after a specific number of the data are loaded from dataset "l\_customer".

### Step

1. Add a console for display the value"load next called".

   ![](https://399701567-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FwmJ1RKjM2uNFaL6fO3Xu%2Fuploads%2Fgit-blob-ca1978460db83d2155a8411bd3309943da172084%2FloadNext-step-1.png?alt=media)
2. Call the function "loadNext" and define the dataset.\
   dataset: l\_customer

   ![](https://399701567-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FwmJ1RKjM2uNFaL6fO3Xu%2Fuploads%2Fgit-blob-ef716dd6f6b57018ce385224858e6ae99e494502%2FloadNext-step-2.png?alt=media)

### Result

![](https://399701567-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FwmJ1RKjM2uNFaL6fO3Xu%2Fuploads%2Fgit-blob-46033e8dc650ab4a3962ca698d6b9d5e296e787e%2FloadNext-result-1.png?alt=media)\
(Add a console and set the value "load next called" just let you more clear to see the different result between load data and load next function.)

![](https://399701567-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FwmJ1RKjM2uNFaL6fO3Xu%2Fuploads%2Fgit-blob-876b6ac89075879b0f0c625bfa42d0664e64f85b%2FloadNext-result-2.png?alt=media)<br>

( When you call the function "loadNext", the rest of the data will be display it continuously. )

## Links
