(3) Create the navigation block on the left
•'------------------------------------------------the web pages---------------------------------------------------------
•
•IF BeginPage THEN 'check if user is logged in
•
•  cStatus=Form("Status")
•  IF cCommand="Submit" THEN
•    cStatus="Submitted"
•  END IF
•  cEditApplication=IIF(cStatus="New Application","Edit Application","View Application")
•  IF cCommand="Edit Application" AND cStatus="New Application" THEN
•    bEditRecord=TRUE
•  END IF
• 
•  'handle logout and switching between view and edit mode
•  DoLogin cCommand                                            ‘handle login/logout