Article Index

This function prints out the main menu and was made to make the main program more readable and modular.

#include "project.h"

char DisplayMainMenu(void)
{
	char return_value;                                       //Declare return value variable

	Header();
	printf("\nO\tOpen database");                             //Display Menu
	printf("\nA\tAdd new record");
	printf("\nS\tSearch for a record");
	printf("\nB\tBrowse the database");
	printf("\nE\tEdit a Record");
	printf("\nD\tDelete a record");
	printf("\nC\tClose the database");
	printf("\nQ\tQuit\n");

	return_value = GetMainMenuChoice("Please enter your choice: ");

	return(return_value);
}
Log in to comment