Switching Between Two Anchors Points by Clicking on a Button

Hi,
You can create a function that uses scrollTo method and toggle between 2 anchor.
It should look something like this:

let scrollTo = 'top';
function button_onclick(event, $w) {
  if (scrollTo === 'top') {
    $w('#topAnchor').scrollTo();
    scrollTo = 'bottom';
  } else {
    $w('#bottomAnchor').scrollTo();
    scrollTo = 'top';
  }
}

Good luck!
Roi.