---
schema_version: "1"
id: 894bb2670de4ae73ba01daff6c3a6739246ad997573aee3762a049cdad4dbfbf
title: refresh Method
collection: developer
version: current
locale: en-us
portal_url: https://docs.salesforce.com/developer/current/en-us/analytics/dashboard-component/guides/bi-dbcomp-refreshmethod.md
canonical_url: https://developer.salesforce.com/docs/analytics/dashboard-component/guide/bi-dbcomp-refreshmethod.html
source_site: developer.salesforce.com
content_type: documentation
content_hash: 9f35219401ac298678fb7e3c4fcd64ecc82f4602f6cca92e25f5e6a83764a1d5
products:
  - Analytics Dashboard Component
  - analytics
---
# refresh Method

Use the `refresh` method to rerun all of the queries for an Aura component for CRM Analytics dashboards or for a specific query.

## Arguments

| Argument Name | Description                                                                                                                                                                                                                                                                  |
| ------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `config`      | The optional configuration for the `refresh` call. This value is a JSON object that sets parameters for the call. For `refresh`, the `config` is used when refresh is called for a single query on the dashboard. To specify which query to rerun, use the `step` parameter. |

## Example

Add your implementation of the `refresh` call into the controller.js for your Aura component. The optional `config` JSON is created with the `step` attribute to rerun the query for a specific step. To rerun all the queries for a dashboard, call `refresh` without the `config` attribute.

```javascript
({
  refresh: function (component, event, helper) {
    var dashboard = component.find("myDashboard");

    var config = {
      step: "step_id",
    };

    dashboard.refresh(config);
  },
});
```

**See Also**

- [`getState` Method](https://developer.salesforce.com/docs/analytics/dashboard-component/guide/bi-dbcomp-getstatemethod.md)
- [`setState` Method](https://developer.salesforce.com/docs/analytics/dashboard-component/guide/bi-dbcomp-setstatemethod.md)
