You are on page 1of 18

Contact Management System

Contact
Manage
ment
System

1
Contact Management System

ACKNOWLEDGEMENT

It's difficult to do some work if we are unknown about how they can be done. We are
dealing with "Contact Management System". After lots of guidance and help from many
people we are able to create a "Contact Management System" application.

2
Contact Management System
We are very thankful to Er. Sonalal Yadav , who provided and created that golden
opportunity of doing this project . Your dedication towards our project was remarkable
and hope it will always be the same. As the project coordinator his helpful hands were
always there till end of this project.
We wish to give our grateful acknowledgement to all and those who created,
manages the easy and reliable situation to complete this project and simply make it a
complete software.

Group Members:

Introduction:
This application is specially designed for creating contacts, editing contacts, update
contacts, delete a contact, and search a contact. This application only relates with contact
management system. The world is changing day by day. So we need to use advance

3
Contact Management System
technology to change daily life system. It makes efficient and easy in daily life system. So
everybody need to change the process of saving contacts for future use.
Nowadays, technology is the one which is fulfilling the demands of human in the
earth. We can also say that the human are the laziest creature on the earth. Human wants
to do work with less efforts and easily. Technology made humans to work with less efforts
and easy so technology had become popular among humans. As we know the needs of
human increases day by day so to fulfill the need technology is also growing day by day.
There are many technology in this earth, among all the technology we are going to discuss
about computer technology. Many programs were and are developed day by day. Among
many program we choose contact management system. We made contact management
system easier to use.
This software is designed simply and main theme to design simply is making the
program simple to use. The person with basic knowledge of computer can handle this
software easily.
This program is based on CUI (Character User Interface). As we know, in CUI the
inputs are given to the computer through the keyboard. No graphics are used in our
program. In this program we give command to the computer through keyboard. In this
program, keyboard must be required till the end of the program.
The contact of each person is saved in a detailed way from different identical name.
Due to following reason the system is to be needed:
• Easily finds the details of contacts
• Simultaneously updates changes made to any contact information.
• It is faster than manual system.
• It gives the contact saver security system

Advantages:
• It is faster, easier and reliable.
• It reduce data redundancy and insecurity.

4
Contact Management System
• It saves time.

Aim and Objective:


• Centralized towards the development of the software product.
• Removing the problems faced with the old traditional contact management system.
• To develop the computerized and efficient contact management system.
• To provide the service to the customers.
• To avoid the man made mistakes.
• To improve the quality of the contact management system.

Functions:
• The system allow anyone to browse the view the system but only the user can make
change in contact information.
• Since the contact name is unique the system must be given a message if the entered
contact name is not available.
• The system allow any user to login into the system.
• The system allow user to search their contact details.
• The system allow user to delete a contact.
• The system allow the check for the update to the contact.

Program Explanation:
Main menu: It is the first menu which appears after the program is executed. This involves
many activities related to Contact Management System.

5
Contact Management System

Activities Involved (with screenshots):


1) Add a contact: This activity allow any user to add new data and information on the
system. It is the main activity of Contact Management System. To edit, delete,
search and update any data it's impossible until we add some data in the system. So
mainly we focus the activity Adda contact.

2) List all contacts:This activity list or show in the list of contacts information's which
are added by the activity Add a contact. We involved this activity in the program
because sometimes the user need to watch the detail of contacts or to know how
many contacts the user had added.
6
Contact Management System

3) Search for contact: Sometime we have to search for the added contacts. This activity
allow user to search contacts faster than checking manually at the list of contacts.
This reduces the effort and saves time.

4) Edit a contact: Sometimes the added contacts may be wrong or needs to be


updated. For updating and correcting contact information we added the activity Edit
a contact.

7
Contact Management System

5) Delete a contact:This activity is just opposite of Add a contactactivity. Sometimes we


may add useless contacts or simply the contacts we do not need. For such type of
contacts this activity plays vital role. This activity is used for deleting or removing
such useless contacts from our system.

6) Exit: If we want to terminate our program then this activity helps us to get quit of the
program. After exiting, our program "Contact Management System" gets closed.

8
Contact Management System

ER Diagram:

Search a contact

List all Contacts


Add a contact

Edit a Delete a Contact

Contact Contact Management System

9
Contact Management System
Exit

System Requirements:
1) Computer with minimum 256Mb Ram
2) Supports all Versions of OS.

Source Code:
#include<stdio.h>
#include<conio.h>
#include<string.h>
#include<process.h>
#include<stdlib.h>
#include<dos.h>
struct contact
{
10
Contact Management System
long ph;
char name[20],add[20],email[30];
} list;
char query[20],name[20];
FILE *fp, *ft;
int i,n,ch,l,found;
int main()
{
main:
system("cls"); /* ************Main menu *********************** */
printf("\n\t **** Welcome to Contact Management System ****");
printf("\n\n\n\t\t\tMAIN MENU\n\t\t=====================\n\t\t[1] Add a new
Contact\n\t\t[2] List all Contacts\n\t\t[3] Search for contact\n\t\t[4] Edit a Contact\n\t\t[5]
Delete a Contact\n\t\t[0] Exit\n\t\t=================\n\t\t");
printf("Enter the choice:");
scanf("%d",&ch);
switch(ch)
{
case 0:
printf("\n\n\t\tAre you sure you want to exit?");
break;
/* *********************Add new contacts************ */
case 1:
system("cls");
fp=fopen("contact.dll","a");
for (;;)

11
Contact Management System

{
fflush(stdin);
printf("To exit enter blank space in the name input\nName (Use identical):");
scanf("%[^\n]",&list.name);
if(stricmp(list.name,"")==0 || stricmp(list.name," ")==0)
break;
fflush(stdin);
printf("Phone:");
scanf("%ld",&list.ph);
fflush(stdin);
printf("address:");
scanf("%[^\n]",&list.add);
fflush(stdin);
printf("email address:");
gets(list.email);
printf("\n");
fwrite(&list,sizeof(list),1,fp);
}
fclose(fp);
break;
/* *********************list of contacts************************* */
case 2:
system("cls");
printf("\n\t\t================================\n\t\t\tLIST OF
CONTACTS\n\t\t================================\n\nName\t\tPhone No\t
12
Contact Management System
Address\t\tE-mail
ad.\n=================================================================\n\n")
;
for(i=97; i<=122; i=i+1)
{
fp=fopen("contact.dll","r");
fflush(stdin);
found=0;
while(fread(&list,sizeof(list),1,fp)==1)
{
if(list.name[0]==i || list.name[0]==i-32)
{
printf("\nName\t: %s\nPhone\t: %ld\nAddress\t: %s\nEmail\t: %s\n",list.name,
list.ph,list.add,list.email);
found++;
}
}
if(found!=0)
{
printf("===========================================================
[%c]-(%d)\n\n",i-32,found);
getch();
}
fclose(fp);
}
break;

13
Contact Management System

/* *******************search contacts********************** */
case 3:
system("cls");
do
{
found=0;
printf("\n\n\t..::CONTACT SEARCH\n\t===========================\n\t..::Name
of contact to search: ");
fflush(stdin);
scanf("%[^\n]",&query);
l=strlen(query);
fp=fopen("contact.dll","r");
system("cls");
printf("\n\n..::Search result for '%s'
\n===================================================\n",query);
while(fread(&list,sizeof(list),1,fp)==1)
{
for(i=0; i<=l; i++)
name[i]=list.name[i];
name[l]='\0';
if(stricmp(name,query)==0)
{
printf("\n..::Name\t: %s\n..::Phone\t: %ld\n..::Address\t: %s\n..::Email\t:
%s\n",list.name,list.ph,list.add,list.email);
found++;

14
Contact Management System

if (found%4==0)
{
printf("..::Press any key to continue...");
getch();
}
}
}
if(found==0)
printf("\n..::No match found!");
else
printf("\n..::%d match(s) found!",found);
fclose(fp);
printf("\n ..::Try again?\n\n\t[1] Yes\t\t[0] No\n\t");
scanf("%d",&ch);
}
while(ch==1);
break;
/* *********************edit contacts************************/
case 4:
system("cls");
fp=fopen("contact.dll","r");
ft=fopen("temp.dat","w");
fflush(stdin);
printf("..::Edit contact\n===============================\n\n\t..::Enter the name
of contact to edit:");
15
Contact Management System

scanf("%[^\n]",name);
while(fread(&list,sizeof(list),1,fp)==1)
{
if(stricmp(name,list.name)!=0)
fwrite(&list,sizeof(list),1,ft);
}
fflush(stdin);
printf("\n\n..::Editing '%s'\n\n",name);
printf("..::Name(Use identical):");
scanf("%[^\n]",&list.name);
fflush(stdin);
printf("..::Phone:");
scanf("%ld",&list.ph);
fflush(stdin);
printf("..::address:");
scanf("%[^\n]",&list.add);
fflush(stdin);
printf("..::email address:");
gets(list.email);
printf("\n");
fwrite(&list,sizeof(list),1,ft);
fclose(fp);
fclose(ft);
remove("contact.dll");
rename("temp.dat","contact.dll");
16
Contact Management System

break;
/* ********************delete contacts**********************/
case 5:
system("cls");
fflush(stdin);
printf("\n\n\t..::DELETE A CONTACT\n\t==========================\n\t..::Enter
the name of contact to delete:");
scanf("%[^\n]",&name);
fp=fopen("contact.dll","r");
ft=fopen("temp.dat","w");
while(fread(&list,sizeof(list),1,fp)!=0)
if (stricmp(name,list.name)!=0)
fwrite(&list,sizeof(list),1,ft);
fclose(fp);
fclose(ft);
remove("contact.dll");
rename("temp.dat","contact.dll");
break;
default:
printf("Invalid choice");
break;
}
printf("\n\n\n..::Enter the Choice:\n\n\t[1] Main Menu\t\t[0] Exit\n");
scanf("%d",&ch);
switch (ch)
17
Contact Management System

{
case 1:
goto main;
case 0:
break;
default:
printf("Invalid choice");
break;
}
return 0;
}

Conclusion:
As conclusion, after the workout of several months in a group, taking the helps and
guides, finally we are able to develop the required system in c-compiler (Turbo C).
We realize that it's easy to work in the group many thoughts are shared between us.

18

You might also like