solved paging problem