I am creating a PCF control that can be used to visualize a list of activities. It's important this control visualizes quickly, so as an optimization I want to add a filter on the dataset which only retrieves recent records. When this dataset is loaded and the user can click, I remove the filter and all records are loaded in the background, allowing the user to start working (assuming the already loaded records are what the user wants to view).

Basically, the control works as follows:

- init, setFilter with date > 14 ago and date < next 14 days,

- updateView, first page of results, updates the visible data 

- updateView, next page (if applicable) 


- In the last updateView when all pages are loaded, the filter is removed, and the dataset is refreshed using context.parameters.dataSet.refresh().

- updateView, first page of results, updates all data (since no filtering is applied).

- updateView, next page (if applicable)

    ... etc.

This works like a charm if the initial result has multiple pages. 

However, when I try to refresh a dataset which has only one page, the new filter (which should return all records) is never applied and exactly the same records are returned after the refresh().

Am I doing something wrong? I tried clearing the filter before setting it, resetting the paging, changing the page size, but nothing seems to trigger an update for the record set if the initial one is only one page.

Kind regards, 

Maarten van Sambeek