Some pagenum related fixes