Fixed issue with on-demand like downloading for last page (paging property isnt available on the last page in my case, so I have added an additional condition for this case)