Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #ifndef menu_h
- #define menu_h
- #include <stdio.h>
- void LaunchMenu()
- {
- char msgHelp[] =
- "Выберите функцию : \n1. Заполнение базы данных\n2. Добавление записи в базу\n3. Удаление заданной записи из базы\n4.Поиск записи по заданному полю\n5.Редактирование заданной записи в файле\n6.Сортировка данных в базе по заданному полю\n7.Вывод на экран содержимого базы в табличном виде";
- char msgOnError[] = "Некорекктный ввод. Выберите функцию из списка";
- puts(msgHelp);
- char userInput;
- scanf("%c", &userInput);
- if(userInput == '1')
- FillData();
- else if(userInput == '2')
- AddRecord();
- else if(userInput == '3')
- DeleteRecord();
- else if(userInput == '4')
- FindWithPart();
- else if(userInput == '5')
- EditRecord();
- else if(userInput == '6')
- SortByField();
- else if(userInput == '7')
- ShowTable();
- else
- {
- puts(msgOnError);
- puts(msgHelp);
- }
- }
- #endif
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement