dynamically change page size