Code:
#include <stdio.h>
#include <<conio.h>
#include <stdlib.h>
int main()
{
char selection;
repeat_menu:
clrscr();
printf("\t\t\t\tKendals\n");
printf("1 = Menu option 1\n");
printf("2 = Menu option 2\n");
// etc
selection=getch();
switch(selection)
{
case '1':
// do stuff for case 1
goto repeat_menu;
break; // just in case
case '2':
// same as 1, do stuff, loop it back to beginning
default:
// user did not choose a valid option, loop
goto repeat_menu;
break;
case 27:
// if the user presses escape, close
break;
}
return 0;
}
pc_apocalypse, VortexOfTech on Yahoo! Messenger.
[email protected]
I've made a few of these. The one I'm working on, having a projected 10,000 lines of code, I could help with anything I can manage to help with!
let me know if this helps...