Unable to end the execution of Data Scrapping

Using the application “E Medical Terms List: Browse the Dictionary | Merriam-Webster
→ if try to scrap the data scrapping through the pagination using clicking on the navigation(>), Once after reaching the last page, its not stopping.

→ If i close the application(browser) in middle of execution manually, “Datatable” is returning eampty data.

Any inputs and solutions please…