Attempt to implement writePage