Fixing incorrect max check

Because currentOffset is updated with the itemsReturned prior to
checking if the max was hit, adding itemsReturned again to
currentOffset will cause an incorrect max hit
added function that enables users to react to network errors and server errors. Also added a function that allows users to tell the autoscroll to stop