#!/bin/bash

PAGENUMBER=0

Page()
{
clear				# Turn new page.
(( PAGENUMBER += 1 ))		# Incrementing page number.
HEADER="Page No. $PAGENUMBER"	# That is your desired header for pages?
if [ -n "$1" ]			# If function called with non-zero param...
then
echo $HEADER, $1		# ...then echo header with string in parameter;...
else
echo $HEADER			# ...or echo header only.
fi
echo ""
read				# And press Enter to turn next page.
}

Page beginning
Page middle
Page end
exit 0