Hi !
i checked your website, your setting the count value before adding the filter so that’s why your getting the old filter’s count instead of the new one. first you should add the filter then count the items, try the following:
$w('#dataset1').setFilter(newFilter).then(() => {
count = $w("#dataset1").getTotalCount();
$w('#result').text = count.toString(); // setting the count value
})
Massa