Multiple for loops within a Menu?

I have program that I want to be able to use I guess you would call them functions.... to run muliple little programs or loops with one menu script. How would I do this. Here is some code I am using. Sorry about the formatting....it doesn't paste well.

echo    "***************************** Starting Patrol Menu  ***************************************"
echo    "                                                                                           "
banner  "Patrol TOOLS"

while true
do
   echo "                                                                                           "
   echo " Choose Option Number & Press Enter to Execute                                             " 
   echo "                                                                                           "
   echo "1.  Check Patrol Agent Status            6.  Display Operator Event Listener Log           "
   echo "2.  Display Active Patrol processes      7.  Display Operator Event Monitor Log            "
   echo "3.  Shutdown Patrol Agent                8.  View Patrol All MQEvents Log                  "          
   echo "4.  Start Patrol Agent                   9.  Suspend Channel Monitoring                    "
   echo "5.  Suspend Channel Monitoring          10.  Re-Activate Channel Monitoring                "
   echo "-->\c"
   read
   case $REPLY in
        1 )    ps -ef | grep PatrolAgent;; 
        2 )    ps -ef | grep patrol | page ;;
        3 )    /mqadmin/patrol/util/pmq_agent_listener_shutdown.ksh;;
        4 )    /patrol/StartPatrol.ksh;;
        5 )    mv echo "This option not currently Available" ;;
        6 )    page /patrol/evntlsr.log ;;;;
        7 )    page /patrol/evmon.log ;;
        9 )    echo Not available;;
        10 )  echo Not availablel;; 

         8 )   break ;;
   esac
done

added code tags for readability --oombera

I'm assuming you are referring to the use of
"functions" within a shell script. The general usage
would be...

#!/bin/sh

dosomething () {
...
...
}

dootherthing() {
...
...
}

...
...

case $REPLY in
1 ) dosomething;;
2 ) dootherthing;;
...
esac

A good resource to look at might be...
http://www.ooblick.com/text/sh/

Yes, I think that's what I am looking for. So, if I select from the Menu Option 9 and I want Option 9 to run a function or call a function with the program I can just add it to the end of the script after done ?

9 ) pagemeorsomething;;
10 ) dootherthing;;

8 ) break ;;
esac
done

pagemeorsomething () {
mailx -s page joe.blow@unix.com <joe.txt
...
}

dootherthing() {
...
...
}

Actually no, you want to define your functions BEFORE
they are called so you would insert them at the top
but AFTER the first line which should be...

#!/bin/sh (or ksh or bash, etc.)

...this first line properly sets up your execution environment.
Then you write your functions. Then you write your "main"
code.