Project Repor Purchase Order System

Download as doc, pdf, or txt
Download as doc, pdf, or txt
You are on page 1of 53

A

PROJECT REPORT
ON
PURCHASE ORDER SYSTEM
Submitted to the

Kurukshetra University, Kuruksehtra


In partial fulfilment of the requirement for
The Degree of

Bachelor of Commerce
(Computer Application)
Session 2013-2014
Under supervision of:
by:
Ms. Amangeet kaur
Lect,.
Deptt. of Comp.Sc. & App.

Submitted
Anju
B.Com. III(C.A.)

Department of Computer Applications

Mukand Lal National


College
Yamuna Nagar

CERTIFICATE

CONTENTS

Certificate

Acknowledgement

Preface
Introduction to Problem area
Existing System
Limitation of the existing system
Proposed System
Advantages of Proposed System
System Analysis & Designing
Input Design
Output Design
Coding
Output
Limitations of Project

Further Scope

References

ACKNOWLEDGEMENT

ACKNOWLEDGEMENT

This is time to extent my sincere gratitude to those


people who directly or indirectly helped me in implementing this
project beyond all expectation.
I would like to convey my heartily indebtedness to Dr.
Neeti Daryal & Ms. Amangeet Kaur (Lecturer) Deptt. of
Computer Science & Applications whose able guidance, regular
counselling, keen interest, constant encouragement and his will to
help us.
I also like to convey my sincere and special thanks to
Dr. Shelesh Kapoor, Principal, Mukand Lal National College,
Yamuna Nagar for providing me such facilities and infrastructure
required for completion of this project.
I am also grateful to my Parents and friends who gave
me full support and their precious to me to me and my problem,
faced during my project work.
Anju
B.Com. III (CA)

PREFACE

PREFACE

Computers are revolutionalising every aspect of life.


The offices where one work, The departmental stores where
are shop, schools and colleges we attend, The banks where
we transact money and devcies we used in our homes are
being radically attended by computers.
Computers usage is growing leaps & bounds in
business, industry government & institutions of students like
colleges and universities although a lot of work in this
directions has been done and gap between demand and
supply of computer professionals.
So realising this fact & acc. to time demand when
computers are necessary and important achievement. I have
chosen B.Com with Computer Applications at my esteemed
institutions Mukand Lal National College, Yamuna Nagar.

This degree course arises at providing the


students knowledge about various applications of
computes.

INTRODUCTION
TO
PROBLEM AREA

INTRODUCTION TO PROBLEM AREA


Studying the manual system of Purchase Order System and
various information requirements, it has been proposed to develop
the computerize system for transaction. As computer is capable of
processing large amount of data at a very high speed with high
degree of accuracy. The data can be stored in small space for
years together without any trouble and can be retrieved whenever
required in few seconds. In the proposed system, data will be
entered into the computer online. In the "Purchase Order System"
data is mainly stored in the main menu file. This file is further
divided in the purchases. Daily sale, other expenses and quit. In
purchasing goods a menu is there in which files of add item
monthly record are placed.

Then lastly there is quit entry.

Through the quit entry we can come out from the main menu.

10

EXISTING SYSTEM

11

EXISTING SYSTEM

In the manual systems of the entries regarding the raw


material are passed in different books. On the arrival of the
goods the first entries made at the gate and for this a
separate registered is maintained.
The goods are passed to the store and the entry of the
bills is made in the incoming register. A slip is issued by the
stores to confirm the arrival of the goods from the
responsible authority, after confirmation the entry is made
in stores receipt register. These good are sold out as the
demand of the purchaser. These purchase of raw products
is maintained in registers. The register making takes much
more time and also these are calculation which may be
some time not accurate . also there can not be done any
comparative study.

12

LIMITATION OF EXISTING SYSTEM

13

LIMITATION OF EXISTING SYSTEM

1)

The system is complicated one and involves a lot


of hardworking.

2)

It is time consuming one because the calculations


and the operation of reports are manual

3)

The system is unreliable and inaccurate

4)

The maintenance of minimum stock level is


difficult.

5)

System

saves the stationary which cost heavily

now a days.
6)

Mistakes

can

be

in

calculation are manual.

14

this

system

because

PROPOSED SYSTEM

15

PROPOSED SYSTEM
The problem of the manual data processing led to the
introduction of computerized method.

The system

basically follows the same procedure. The entry is made


at gate in register.

The goods being passed on to the

stores and then the bill are recorded in the store incoming
register. The store passes a slip to computer department.
The slip contains ifnormation regarding value of goods,
quality and item code regarding the goods.

The computer department passes the copy daily bill


register to stores to confirm the entry and incoming
goods later. When the goods are issued to the workshop
slip is passed to the computer department and the
respective entries are made onto the computer.

The

department passes the copy of daily issue register to


confirm the issue of all items during the day.

16

ADVANTAGES OF PROPOSED SYSTEM

17

ADVANTAGES OF PROPOSED SYSTEM


1. Large amount of data can be stored with the help of
powerful storage media like floppies, disks etc.
2. Purchasing involves lesser economy
3. This system is useful to enter and store the data
4. Redundancy of information has been controlled.
5. System saves the stationary which costs heavily
nowadays
6. In this system, load is greatly reduced in case of invite
quotation, finalization of quotation and preparing of
transaction orders and reminders etc.

18

SYSTEM ANALYSIS
AND
DESIGNING

19

SYSTEM ANALYSIS
Purchase is defined as any idle in coming resource of an
enterprise. It is physical work of goods kept for the purpose
of future affairs.

It is generally used to indicate raw

material, semi-finished goods and finished goods stocked in


order to meet expected future demand, Inventory is not
meant for immediate use. For enterprises an Inventory of
materials become essential in order.
1

To purchase smooth and efficient running of the


business.

To provide adequate of price discounts bulk purchase

To take advantage of batching and longer production


runs

To serve as a buffer in case of delayed delivers of raw


materials and rejections or against uncertain lead time

To provide feasibility to allow changes in production


plan in view of change in demand etc.

To make possible economic in transportation etc.

To absorb fluctuations in market.


Inventory means lock up of capital of an enterprise.

Maintenance of inventory also cost money by way of


20

expenses or stores, equipments, personal, insurance etc.


This calls for the inventories in the most profitable manner.
Broadly speaking Purchase Order System refers to the
function

of

directions

goods

through

the

entire

manufacturing cycle from the requisition of raw materials to


the

minimum investment and the best possible customer

service.

PURCHASE ORDER SYSTEM:


Basically two types of Purchase Order System can be for
seen.
1

FIXED

PROBALISTIC

A)

ABC ANALYSIS:
When there may items are classified on the basis of

their value, usage rate and critically.

B)

MIN-MAX SYSTEM:
For each type of Inventory minimum level is set that

demands safety to prevent out of stock conditions. The

21

minimum level also gave the ordering proving. An order of


sufficient size is placed to bring the inventory the max front
when the minimum level is reached.

C)

TWO BIN SYSTEM:


In this system, the stock of each items is separated into

two files, in the first a sufficient supply is kept to meet the


current demand during lead time necessary to fill the order.

INVENTORY RISKS:
Can be traced to three basic factors i.e. Price decline,
deterioration and obsolescence.

Price Decline:
May result from any increase in the market supply of

product, introduction of a new competitive produce, or price


cutting by competitors. Price may also decline when the
supply remains same and there is decrease in the general
market demand.

22

Product Deterioration:
May result due to holding of a product too long or when

stocked under improper physical conditions.

Obsolescence:
Changing customer taste, particularly in high style

merchandise may render finished goods and even raw


material absolute. The considering all this we see that
inventories are risky assets to be manage and therefore
calls for a very efficient control.

23

SYSTEM DESIGNING
Designing a software is most important phase of software phase of software
development. It requires careful planning, logical thinking on the part of
system designer. System design for proposed system comes under following
phases:
1. Input Design
2. Output Design
3. File Design
4. Input Design:
Input designing is a part of overall system designing which requires
careful attention as collection of input data is most expensive part of the
system. Inputs are used to detect errors to some extent in between the
programming procedures. I have included following inputs in my project of
"Trading Co. Transaction" When project is executed following main menu
is printed.

Main Menu
P

PRODUCT MASTER

ORDER PLACEMENT

VENDOR MASTER

ISSUE MASTER

REPORT MASTER

EXIT

When first option is selected then Received Material Menu will be displayed
with data entry regarding purchases of new goods.

24

INPUT DESIGN OF SALES MENU


1

Good Code:
It is the number given to product for identification. This number
should be falling within 1,2,3 numbers which are specified.

Good Name:
It tells the name of the Good which is sold to the customer. Without
knowing the name of Good one can't sell that Good.

Customer Name & Address:


It is required for issuing the bill. It tells whom the Good is sold.

Unit Price:
It tells the price of the Good. It tells how much the Good costs and
gives its unit price.

OUTPUT DESIGN:
Outputs are required to produce result of processing to the user. Output will
be in the form of a screen where different options will be displayed. In
output designing there is report menu. IT is fourth option of main menu. It
gives the output design of the system. It has been further divided to three
options given below.
ISSUE MASTER
E

ISSUE ENTRY

ISSUE MODIFY ENTRY

ISSUE QUERY ENTRY

25

EXIT

NEXT MENU IS OF REPORT: It has following options:


REPORT MASTER
I

ITEM REPORT

ISSUE REPORT

EXIT

FILE DESIGN
struct
{char pcode[5};
char pname[20];
char desc[20];
char type[3];
char unitp[5];
char qty[5];
char max[5];
char min[5];
}product, mproduct;
This structure defines the product details in respect to there data type.
struct
{char pcode[5];
char pname[20];
char desc[20];
char min[3];
char qty[5];
char max[5];

26

char unitp[5];
char type[3];
}item;
This structure defines the issue item details in respect to there data type.
char pcode[5] : It defines the product code.
char pname[20] : It defines the product name.
char desc[20] : It defines the description of goods.
char min[3] : It determines the min qty.
char qty[5] : Current qty.
char max[5] : Maximum qty.
char unitp[5] : Unit Price
char type[3] : Goods type
The basic data types are same so major data variables are defined.

27

CODING

28

/*

PURCAHSE ORDER SYSTEM */

#include<stdio.h>
#include<conio.h>
#include<dos.h>
#include<string.h>
#include<process.h>
#include<graphics.h>
#include<ctype.h>
struct
{ char pcode[5];
char pname[20];
char desc[20];
char type[3];
char unitp[5];
char qty[5];
char max[5];
char min[5];
}product,mproduct;
struct
{
char pcode[5];
char pname[20];
char desc[20];
char min[3];
char qty[5];
char max[5];
char unitp[5];
char type[3];
}item;
struct
{ char vcode[5];
char vname[20];
char adde[20];
char city[15];
char contno[10];
char parti[15];
}vender,mvender;
struct
{ char ocode[5];
char qty[8];
char icode[5];
char vcode[5];
char vname[20];
char qtyj[5];
char qtyr[5];
char topaid[5];
char topay[5];
}order,order1,morder;

void main()
{
char ch;
void pmenu(),omenu(),vmenu(),rmenu();
int gd=DETECT,gm=0;
initgraph(&gd,&gm," ");
clrscr();

29

settextstyle(1,0,4);
outtextxy(190,50,"PROJECT");
outtextxy(250,140,"ON");
outtextxy(150,220,"PURCHASE ORDER");
outtextxy(200,300,"SYSTEM");
settextstyle(1,0,3);
outtextxy(250,400,"press any key to continue");
getch();
closegraph();
clrscr();
initgraph(&gd,&gm," ");
settextstyle(1,0,4);
outtextxy(100,40,"PURCHASE ORDER SYSTEM");
settextstyle(1,0,3);
getch();
while(1)
{
clrscr();
setcolor(15);
setfillstyle(1,RED);
rectangle(50,30,550,350);
floodfill(30,50,15);
settextstyle(1,0,3);
outtextxy(100,50, "**** PURCHASE ORDER SYSTEM ****");
outtextxy(160,140," P: PURCHASE PRODUCT");
outtextxy(160,170," O: ORDER PLACING");
outtextxy(160,200," V: VENDOR DATA");
outtextxy(160,230," R: REPORT ");
outtextxy(160,260," E: EXIT");
outtextxy(185,290," ENTER YOUR CHOICE");
ch=getch();
ch=toupper(ch);
switch(ch)
{case 'P' : pmenu();break;
case 'O' : omenu();break;
case 'V' : vmenu();break;
case 'R' : rmenu();break;
case 'E' : break;
}
if (ch=='E')
break;}
}
void pmenu()
{char ch1;
clrscr();
while(1)
{
int gd=DETECT,gm=0;
initgraph(&gd,&gm," ");
clrscr();
setcolor(4);
setfillstyle(1,RED);
rectangle(50,30,550,350);
setcolor(WHITE);
floodfill(30,50,4);
settextstyle(1,0,3);
outtextxy(140,50,"PURCHASE PRODUCT");
outtextxy(160,140,"E : DATA ENTERY MODULE");
outtextxy(160,170,"M : DATA MODIFICATION MODULE");
outtextxy(160,200," Q : DATA QUERY MODULE");
outtextxy(160,230,"X: QUIT");

30

outtextxy(180,260,"enter your choice....." );


ch1=getch();
ch1=toupper(ch1);
switch(ch1)
{case 'E': entry();break;
case 'M': modi();break;
case 'Q': query();break;
case 'X' : break;

if(ch1=='X')
break;
}

void omenu()
{char ch2;
clrscr();
while(1)
{int gd=DETECT,gm=0;
initgraph(&gd,&gm," ");
setcolor(4);
setfillstyle(1,RED);
rectangle(50,30,550,350);
setcolor(WHITE);
floodfill(30,50,4);
settextstyle(1,0,3);
outtextxy(140,50," ORDER PLACE");
outtextxy(80,110,"R : DATA ENTERY MODULE");
outtextxy(80,140,"M : DATA MODIFICATION MODULE");
outtextxy(80,170,"G : GOOD RECEIVE ENTRY MODULE");
outtextxy(80,200,"Q : DATA QUERY MODULE");
outtextxy(80,230,"A : AMOUNT PAYMENT ENTRY MODULE");
outtextxy(80,260,"X : EXIT");
outtextxy(80,290,"enter your choice....." );
ch2=getch();
ch2=toupper(ch2);
switch(ch2)
{case 'R': oentry();break;
case 'M': omodi();break;
case 'Q': oquery();
break;
case 'G': ogood();break;
case 'A': oamount();
break;
case 'X': break;
}
if(ch2=='X')
break;
}
}

void vmenu()
{ char ch3;
clrscr();
while(1)

31

{int gd=DETECT,gm=0;
initgraph(&gd,&gm," ");
setcolor(4);
setfillstyle(1,RED);
rectangle(50,30,550,350);
setcolor(WHITE);
floodfill(30,50,4);
settextstyle(1,0,3);
outtextxy(140,50," VENDOR DATA");
outtextxy(160,110,"E : DATA ENTERY MODULE");
outtextxy(160,140,"M : DATA MODIFICATION MODULE");
outtextxy(160,170,"Q: DATA QUERY MODULE");
outtextxy(160,200,"X : EXIT");
outtextxy(180,230,"enter your choice....." );
ch3=getch();
ch3=toupper(ch3);
switch(ch3)
{case 'E': ventry();break;
case 'M': vmodi();break;
case 'Q': vquery();break;
case 'X': break;
}
}
}

if(ch3=='X')
break;
void rmenu()
{char ch4;
clrscr();
while(1)
{
int gd=DETECT,gm=0;
initgraph(&gd,&gm," ");
setcolor(4);
setfillstyle(1,RED);
rectangle(50,30,550,350);
setcolor(WHITE);
floodfill(30,50,4);
setcolor(WHITE);
settextstyle(1,0,3);
outtextxy(140,50," REPORT");
outtextxy(160,110,"I : ITEM REPORT");
outtextxy(160,140,"V : VENDOR REPORT");
outtextxy(160,170,"O: ORDER REPORT");
outtextxy(160,200,"G: GOOD RECEVING REPORT");
outtextxy(160,230,"A: AMOUNT PAYMENT REPORT");
outtextxy(160,260,"X : EXIT");
ch4=getch();
ch4=toupper(ch4);
switch(ch4)
{case 'I':irep();break;
case 'V':vrep();break;
case 'O':orep();break;
case 'G':grep();break;
case 'A':prep();break;

32

case 'X':break;
}
if(ch4=='X')
break;
}

}
scom(char a[], char b[], int n)
{ int i,r=1;
for(i=0;i<n;++i)
if( a[i]!=b[i])
r=0;
return r;
}

entry()
{char ch='Y',res;
int i,n;
FILE * fp;
fp=fopen("item.dat","ar+");
while(toupper(ch)=='Y')
{closegraph();
clrscr();
gotoxy(10,5);printf(" **** DATA ENTRY MODULE ****");
gotoxy(10,7);printf("
CODE OF PRODUCT
");
gotoxy(10,8);printf("
NAME OF PRODUCT
");
gotoxy(10,9);printf("
DESCRIPTION
");
gotoxy(10,10);printf("
TYPE
");
gotoxy(10,11);printf("
PRINCE PER UNIT
");
gotoxy(10,12);printf("
QUANTITY
");
gotoxy(10,13);printf("
MAX. QTY.
");
gotoxy(10,14);printf("
MIN. QTY.
");
gotoxy(38,7);gets(product.pcode);
gotoxy(38,8);gets(product.pname);
gotoxy(38,9);gets(product.desc);
gotoxy(38,10);gets(product.type);
gotoxy(38,11);gets(product.unitp);
gotoxy(38,12);gets(product.qty);
gotoxy(38,13);gets(product.max);
gotoxy(38,14);gets(product.min);
gotoxy(20,15);printf("Entries Correct Y/N");
res=getch();
if(toupper(res)=='Y')
{ for(i=0;i<=4;++i)
product.pcode[i]=toupper(product.pcode[i]);
for(i=0;i<=19;++i)
product.pname[i]=toupper(product.pname[i]);
for(i=0;i<=19;++i)
product.desc[i]=toupper(product.desc[i]);
for(i=0;i<=2;++i)
product.type[i]=toupper(product.type[i]);
for(i=0;i<=4;++i)
product.unitp[i]=toupper(product.unitp[i]);
for(i=0;i<=4;++i)
product.qty[i]=toupper(product.qty[i]);

33

for(i=0;i<=4;++i)
product.max[i]=toupper(product.max[i]);
for(i=0;i<=4;++i)
product.min[i]=toupper(product.min[i]);
n=strlen(product.pcode);
con(product.pcode,n,5);
n=strlen(product.pname);
con(product.pname,n,20);
n=strlen(product.desc);
con(product.desc,n,20);
n=strlen(product.type);
con(product.type,n,3);
n=strlen(product.unitp);
con(product.unitp,n,5);
n=strlen(product.qty);
con(product.qty,n,5);
n=strlen(product.max);
con(product.max,n,5);
n=strlen(product.min);
con(product.min,n,5);
fwrite(&product,sizeof(product),1,fp);
}
gotoxy(1,23);printf("Press Y to continue");
ch=getch();
}
fclose(fp);
return;
}
con(char sa[],int n,int tlen)
{int i;
for(i=0;i<n;++i)
sa[i]=toupper(sa[i]);
for(i=n;i<tlen;++i)
sa[i]=' ';
return;
}

modi()

char ch='Y',res;
char mpcode[5];
char mpname[20];
char mdesc[20];
char mtype[3];
char munitp[5];
char mqty[5];
char mmax[5];
char mmin[5];
int i,count=0,recsize=sizeof(product),n,l1;
FILE *fp;
fp=fopen("item.dat","r+");
while(toupper(ch)=='Y')
{ closegraph();
clrscr();
rewind(fp);
gotoxy(10,5);printf(" *** DATA MODIFICATION MODULE ***");
gotoxy(10,7);printf("
CODE OF PRODUCT
");

34

gotoxy(10,8);printf("
NAME OF PRODUCT
");
gotoxy(10,9);printf("
DESCRIPTION
");
gotoxy(10,10);printf("
TYPE
");
gotoxy(10,12);printf("
PRINCE PER UNIT
");
gotoxy(10,11);printf("
QUANTITY
");
gotoxy(38,7);gets(mpcode);
for(i=0;i<=4;++i)
mpcode[i]=toupper(mpcode[i]);
while(fread(&product,sizeof(product),1,fp)==1)
{n=strlen(mpcode);
if(scom(product.pcode,mpcode,n)==1)
{++count;
gotoxy(38,8);for(i=0;i<20;++i)
printf("%c",product.pname[i]);
gotoxy(38,9);for(i=0;i<20;++i)
printf("%c",product.desc[i]);
gotoxy(38,10);for(i=0;i<3;++i)
printf("%c",product.type[i]);
gotoxy(38,11);for(i=0;i<5;++i)
printf("%c",product.qty[i]);
gotoxy(38,12);for(i=0;i<5;++i)
printf("%c",product.unitp[i]);
gotoxy(38,8);gets(mpname);
gotoxy(38,9);gets(mdesc);
gotoxy(38,10);gets(mtype);
gotoxy(38,11);gets(mqty);
gotoxy(38,12);gets(munitp);
gotoxy(20,15);printf("Entries Correct Y/N : ");
res=getche();
if(toupper(res)=='Y')
{
n=strlen(product.pname);
con(product.pname,n,20);
n=strlen(product.desc);
con(product.desc,n,20);
n=strlen(product.type);
con(product.type,n,3);
n=strlen(product.qty);
con(product.qty,n,5);
n=strlen(product.unitp);
con(product.unitp,n,5);
fseek(fp,-recsize,SEEK_CUR);
fwrite(&product,sizeof(product),1,fp);
}
}
}
if(count==0)
{gotoxy(35,20);printf("record not found");}
gotoxy(1,23);printf("Press Y to Continue
ch=getch();

}
fclose(fp);
return;
}

query()

35

");

{ char ch='Y',res;
char mpcode[5];
int i,n,count=0;
FILE *fp;
fp=fopen("item.dat","r");
while(toupper(ch)=='Y')
{closegraph();
count=0;
clrscr();
rewind(fp);
gotoxy(10,5);printf(" *** DATA QUERY MODULE ***");
gotoxy(10,7);printf("
CODE OF PRODUCT
");
gotoxy(10,8);printf("
NAME OF PRODUCT
");
gotoxy(10,9);printf("
DESCRIPTION
");
gotoxy(10,10);printf("
TYPE
");
gotoxy(10,12);printf("
PRINCE PER UNIT
");
gotoxy(10,11);printf("
QUANTITY
");
gotoxy(38,7);gets(mpcode);
for(i=0;i<=4;++i)
mpcode[i]=toupper(mpcode[i]);
while(fread(&product,sizeof(product),1,fp)!=0)
n=strlen(mpcode);
if (scom(product.pcode,mpcode,n)==1)
{ ++count;
gotoxy(38,8);for(i=0;i<20;++i)
printf("%c",product.pname[i]);
gotoxy(38,9);for(i=0;i<20;++i)
printf("%c",product.desc[i]);
gotoxy(38,10);for(i=0;i<3;++i)
printf("%c",product.type[i]);
gotoxy(38,11);for(i=0;i<5;++i)
printf("%c",product.qty[i]);
gotoxy(38,12);for(i=0;i<5;++i)
printf("%c",product.unitp[i]);
}
if(count==0)
{ gotoxy(30,15);printf("Record not found");}
gotoxy(1,23);printf("Press Y to Continue
ch=getch();
}
}

");

fclose(fp);
return;

oentry()
{
char ch='Y',res;
int i;
FILE *fp;
fp=fopen("order.dat","ar+");
while(toupper(ch)=='Y')
{closegraph();
clrscr();
gotoxy(10,5);printf(" *** DATA ENTRY MODULE *** ");
gotoxy(10,7);printf("
ORDER CODE
");

36

gotoxy(10,8);printf("
ITEM CODE
");
gotoxy(10,9);printf("
VENDOR CODE
gotoxy(10,10);printf("
VENDOR NAME
gotoxy(10,11);printf("
QUANTITY
gotoxy(38,7);gets(order.ocode);
gotoxy(38,8);gets(order.icode);
gotoxy(38,9);gets(order.vcode);
gotoxy(38,10);gets(order.vname);
gotoxy(38,11);gets(order.qty);
gotoxy(20,15);printf("Entries Correct Y/N");
res=getch();
if(toupper(res)=='Y')
{// clrscr();
for(i=0;i<=4;++i)
order.ocode[i]=toupper(order.ocode[i]);
for(i=0;i<=4;++i)
order.icode[i]=toupper(order.icode[i]);
for(i=0;i<=4;++i)
order.vcode[i]=toupper(order.vcode[i]);
for(i=0;i<=19;++i)
order.vname[i]=toupper(order.vname[i]);
for(i=0;i<=7;++i)
order.qty[i]=toupper(order.qty[i]);
fwrite(&order,sizeof(order),1,fp);
}
gotoxy(1,23);printf("press Y to continue....");
ch=getch();
}
fclose(fp);
return;
}

");
");
");

omodi()
{ char ch='Y',res;
char mocode[5];
char mqty[8];
char micode[5];
char mvcode[5];
char mvname[20];
int i,count=0,n,recsize=sizeof(order);
FILE *fp;
fp=fopen("order.dat","r+");
while(toupper(ch)=='Y')
{ closegraph();
clrscr();
rewind(fp);
gotoxy(10,5);printf(" *** DATA MODIFICATION MODULE *** ");
gotoxy(10,7);printf("
ORDER CODE
");
gotoxy(10,8);printf("
ITEM CODE
");
gotoxy(10,9);printf("
VENDOR CODE
");
gotoxy(10,10);printf("
VENDOR NAME
");
gotoxy(10,11);printf("
QUANTITY
");
gotoxy(38,7);gets(mocode);
for(i=0;i<=4;++i)
mocode[i]=toupper(mocode[i]);
while(fread(&order,sizeof(order),1,fp)==1)
{ n=strlen(mocode);
if(scom(order.ocode,mocode,n)==1)
{++count;

37

gotoxy(38,8);for(i=0;i<5;++i)
printf("%c",order.icode[i]);
gotoxy(38,9);for(i=0;i<5;++i)
printf("%c",order.vcode[i]);
gotoxy(38,10);for(i=0;i<20;++i)
printf("%c",order.vname[i]);
gotoxy(38,11);for(i=0;i<8;++i)
printf("%c",order.qty[i]);
gotoxy(38,8);gets(micode);
gotoxy(38,9);gets(mvcode);
gotoxy(38,10);gets(mvname);
gotoxy(38,11);gets(mqty);
gotoxy(20,15);printf("Entries Are Correct Y/N....");
res=getche();
if(toupper(res)=='Y')
{ n=strlen(order.icode);
con(order.icode,n,5);
n=strlen(order.vcode);
con(order.vcode,n,5);
n=strlen(order.vname);
con(order.vname,n,20);
n=strlen(order.qty);
con(order.qty,n,8);
fseek(fp,-recsize,SEEK_CUR);
fwrite(&order,sizeof(order),1,fp);
}
}

}
{
}
}

if(count==0)
gotoxy(35,20);printf("RECORD NOT FOUND");}
gotoxy(1,23);printf("Press Y to continue");
ch=getch();
fclose(fp);
return;

oquery()
{
char ch='Y',res;
char mocode[5];
int i,n,count=0;
FILE * fp;
fp=fopen("order.dat","r");
while(toupper(ch)=='Y')
{closegraph();
count=0;
clrscr();
rewind(fp);
gotoxy(10,5);printf(" *** DATA QUERY MODULE ***");
gotoxy(10,7);printf("
ORDER CODE
");
gotoxy(10,8);printf("
ITEM CODE
");
gotoxy(10,9);printf("
VENDOR CODE
");
gotoxy(10,10);printf("
VENDOR NAME
");
gotoxy(10,11);printf("
QUANTITY
");
gotoxy(38,7);gets(mocode);
for(i=0;i<=4;++i)
mocode[i]=toupper(mocode[i]);
while(fread(&order,sizeof(order),1,fp)!=0)

38

n=strlen(mocode);
if(scom(order.ocode,mocode,n)==1)
{ ++count;
gotoxy(38,8);for(i=0;i<8;++i)
printf("%c",order.qty[i]);
gotoxy(38,9);for(i=0;i<5;++i)
printf("%c",order.icode[i]);
gotoxy(38,10);for(i=0;i<5;++i)
printf("%c",order.vcode[i]);
gotoxy(38,11);for(i=0;i<20;++i)
printf("%c",order.vname[i]);
}
if(count==0)
{
gotoxy(30,15);printf("Record not found");
}
gotoxy(1,23);printf("Press Y to Continue
ch=getch();
}
fclose(fp);
return;
}

");

ventry()
{ char ch='Y',res;
int i;
FILE *fp;
fp=fopen("vender.dat","ar+");
while(toupper(ch)=='Y')
{closegraph();
clrscr();
gotoxy(10,5);printf(" *** DATA ENTRY MODULE ***
gotoxy(10,7);printf(" VENDOR CODE
gotoxy(10,8);printf(" VENDOR NAME
gotoxy(10,9);printf(" VENDOR ADDRESS
gotoxy(10,10);printf(" CITY
gotoxy(10,11);printf(" CONTACT NO.
gotoxy(10,12);printf(" PARTICULARS
gotoxy(38,7);gets(vender.vcode);
gotoxy(38,8);gets(vender.vname);
gotoxy(38,9);gets(vender.adde);
gotoxy(38,10);gets(vender.city);
gotoxy(38,11);gets(vender.contno);
gotoxy(38,12);gets(vender.parti);
gotoxy(20,15);printf("Entries Correct Y/N");
res=getch();
if(toupper(res)=='Y')
{for(i=0;i<=4;++i)
vender.vcode[i]=toupper(vender.vcode[i]);
for(i=0;i<=19;++i)
vender.vname[i]=toupper(vender.vname[i]);
for(i=0;i<=19;++i)
vender.adde[i]=toupper(vender.adde[i]);
for(i=0;i<=14;++i)
vender.city[i]=toupper(vender.city[i]);

39

");
");
");
");
");
");
");

for(i=0;i<=9;++i)
vender.contno[i]=toupper(vender.contno[i]);
for(i=0;i<=14;++i)
vender.parti[i]=toupper(vender.parti[i]);
fwrite(&vender,sizeof(vender),1,fp);
}
gotoxy(1,23);printf("press Y to continue....");
ch=getch();
}
fclose(fp);
return;
}
vmodi()
{
char ch='Y',res;
char mvcode[5];
char mvname[20];
char madde[20];
char mcity[15];
char mcontno[10];
char mparti[15];
int i,n,count=0,recsize=sizeof(vender);
FILE *fp;
fp=fopen("vender.dat","r+");
while(toupper(ch)=='Y')
{closegraph();
clrscr();
rewind(fp);
gotoxy(10,5);printf(" *** DATA MODIFICATION MODULE *** ");
gotoxy(10,7);printf(" VENDOR CODE
");
gotoxy(10,8);printf(" VENDOR NAME
");
gotoxy(10,9);printf(" VENDOR ADDRESS
");
gotoxy(10,10);printf(" CITY
");
gotoxy(10,11);printf(" CONTACT NO.
");
gotoxy(10,12);printf(" PARTICULARS
");
gotoxy(38,7);gets(mvcode);
for(i=0;i<=4;++i)
mvcode[i]=toupper(mvcode[i]);
while(fread(&vender,sizeof(vender),1,fp)==1)
{n=strlen(mvcode);
if(scom(vender.vcode,mvcode,n)==1)
{++count;
gotoxy(38,8);puts(vender.vname);
gotoxy(38,9);puts(vender.adde);
gotoxy(38,10);puts(vender.city);
gotoxy(38,11);puts(vender.contno);
gotoxy(38,12);puts(vender.parti);
gotoxy(38,8);gets(mvname);
gotoxy(38,9);gets(madde);
gotoxy(38,10);gets(mcity);
gotoxy(38,11);gets(mcontno);
gotoxy(38,12);gets(mparti);
gotoxy(20,15);printf("Entries Are Correct Y/N....");
res=getch();
if(toupper(res)=='Y')
{n=strlen(mvcode);
fseek(fp,-recsize,SEEK_CUR);
fwrite(&vender,sizeof(vender),1,fp);

40

}
}

if(count==0)
{ gotoxy(35,20);printf("RECORD NOT FOUND");}
gotoxy(1,23);printf("Press Y to continue");
ch=getche();

fclose(fp);
return;
}
vquery()
{char ch='Y',res;
char mvcode[5];
int i,count=0;
FILE *fp;
fp=fopen("vender.dat","r");
while(toupper(ch)=='Y')
{closegraph();
count=0;
clrscr();
rewind(fp);
gotoxy(10,5);printf(" *** DATA QUERY MODULE ***");
gotoxy(10,7);printf(" VENDOR CODE
gotoxy(10,8);printf(" VENDOR NAME
gotoxy(10,9);printf(" VENDOR ADDRESS
gotoxy(10,10);printf(" CITY
gotoxy(10,11);printf(" CONTACT NO.
gotoxy(10,12);printf(" PARTICULARS
gotoxy(38,7);gets(mvcode);
for(i=0;i<=4;++i)
mvcode[i]=toupper(mvcode[i]);
while(fread(&vender,sizeof(vender),1,fp)!=0)
if(strcmp(vender.vcode,mvcode)==0)
{ ++count;
gotoxy(38,8);puts(vender.vname);
gotoxy(38,9);puts(vender.adde);
gotoxy(38,10);puts(vender.city);
gotoxy(38,11);puts(vender.contno);
gotoxy(38,12);puts(vender.parti);
}
if(count==0)
{
gotoxy(30,15);printf("Record not found");
}
gotoxy(1,23);printf("Press Y to Continue
");
ch=getch();
}
fclose(fp);
return;
}

oamount()
{
char ch='Y',res;
int i;

41

");
");
");
");
");
");

FILE *fp;
fp=fopen("order1.dat","ar+");
while(toupper(ch)=='Y')
{ closegraph();
clrscr();
gotoxy(20,5);printf(" *** AMOUNT PAYMENT ENTRY *** ");
gotoxy(10,7);printf(" ORDER CODE
");
gotoxy(10,8);printf(" ITEM CODE
");
gotoxy(10,9);printf(" VENDOR CODE
");
gotoxy(10,10);printf(" QUANTITY
");
gotoxy(10,11);printf(" AMOUNT TO BE PAY
");
gotoxy(10,12);printf(" QUANTITY REJECTED
");
gotoxy(10,13);printf(" QUANTITY RECEIVED
");
gotoxy(10,14);printf(" AMOUNT TO BE PAID
");
gotoxy(40,7);gets(order.ocode);
gotoxy(40,8);gets(order.icode);
gotoxy(40,9);gets(order.vcode);
gotoxy(40,10);gets(order.qty);
gotoxy(40,11);gets(order.topay);
gotoxy(40,12);gets(order.qtyj);
gotoxy(40,13);gets(order.qtyr);
gotoxy(40,14);gets(order.topaid);
gotoxy(20,17);printf("Entries Correct Y/N");
res=getch();
if(toupper(res)=='Y')
{
for(i=0;i<=4;++i)
order.ocode[i]=toupper(order.ocode[i]);
for(i=0;i<=4;++i)
order.icode[i]=toupper(order.icode[i]);
for(i=0;i<=4;++i)
order.vcode[i]=toupper(order.vcode[i]);
for(i=0;i<=4;++i)
order.qty[i]=toupper(order.qty[i]);
for(i=0;i<=4;++i)
order.topay[i]=toupper(order.topay[i]);
for(i=0;i<=4;++i)
order.qtyj[i]=toupper(order.qtyj[i]);
for(i=0;i<=4;++i)
order.qtyr[i]=toupper(order.qtyr[i]);
for(i=0;i<=4;++i)
order.topaid[i]=toupper(order.topaid[i]);
fwrite(&order,sizeof(order),1,fp);
}
gotoxy(1,23);printf("Press Y to continue.......");
ch=getche();
}
fclose(fp);
return;
}
ogood()
{
char ch='Y',res;
int i;
FILE *fp;
fp=fopen("order2.dat","ar+");
while(toupper(ch)=='Y')
{ closegraph();
clrscr();

42

gotoxy(20,5);printf(" *** GOOD RECEVING ENTRY *** ");


gotoxy(10,7);printf(" ORDER CODE
");
gotoxy(10,8);printf(" ITEM CODE
");
gotoxy(10,9);printf(" VENDOR CODE
");
gotoxy(10,10);printf(" QUANTITY
");
gotoxy(10,12);printf(" QUANTITY REJECTED
");
gotoxy(10,13);printf(" QUANTITY RECEIVED
");
gotoxy(10,14);printf(" AMOUNT TO BE PAID
");
gotoxy(38,7);gets(order.ocode);
gotoxy(38,8);gets(order.icode);
gotoxy(38,9);gets(order.vcode);
gotoxy(38,10);gets(order.qty);
gotoxy(38,11);gets(order.qtyj);
gotoxy(40,12);gets(order.qtyr);
gotoxy(40,13);gets(order.topay);
gotoxy(20,17);printf("Entries Correct Y/N");
res=getch();
if(toupper(res)=='Y')
{
for(i=0;i<=4;++i)
order.ocode[i]=toupper(order.ocode[i]);
for(i=0;i<=4;++i)
order.icode[i]=toupper(order.icode[i]);
for(i=0;i<=4;++i)
order.vcode[i]=toupper(order.vcode[i]);
for(i=0;i<=4;++i)
order.qty[i]=toupper(order.qty[i]);
for(i=0;i<=4;++i)
order.qtyj[i]=toupper(order.qtyj[i]);
for(i=0;i<=4;++i)
order.qtyr[i]=toupper(order.qtyr[i]);
for(i=0;i<=4;++i)
order.topay[i]=toupper(order.topay[i]);
fwrite(&order,sizeof(order),1,fp);
}
gotoxy(1,23);printf("Press Y to continue.......");
ch=getche();
}
fclose(fp);
return;
}
irep()
{
FILE *fp;
int r,i;
fp=fopen("item.dat","r");
closegraph();
clrscr();
gotoxy(40,3);printf("****STOCK REPORT****");
gotoxy(1,4);printf("---------------------------------------------------------------");
gotoxy(1,5);printf("prod.code
prodname
max
qty
min
");
gotoxy(1,6);printf("___________________________________________________
_____________");
r=8;

43

while(fread(&product,sizeof(product),1,fp) !=0)
{
gotoxy(1,r);for(i=0;i<5;++i)
printf("%c",product.pcode[i]);
gotoxy(16,r);for(i=0;i<20;++i)
printf("%c",product.pname[i]);
gotoxy(30,r);for(i=0;i<5;++i)
printf("%c",product.max[i]);
gotoxy(39,r);for(i=0;i<5;++i)
printf("%c",product.qty[i]);
gotoxy(47,r);for(i=0;i<5;++i)
printf("%c",product.min[i]);
gotoxy(60,r);
if(atoi(product.qty)>atoi(product.max))
printf("Above");
else
{ if(atoi(product.qty)>=atoi(product.min))
printf("Normal");
else
printf("below");}
if(r<=22)
r++;
else
{
gotoxy(2,22);printf("press any key to continue");
getch();
clrscr();
gotoxy(40,3);printf("STOCK REPORT");
gotoxy(1,4);printf("___________________________________________________
__");
gotoxy(1,5);printf("prod.code
prod name
max
qty
min
");
gotoxy(1,6);printf("----------------------------------------------------");
r=10;
}
}
++r;
gotoxy(1,r);printf("--------------------------------------------------------------");
getche();
}

orep()
{
FILE *fp;
int r,i;
fp=fopen("order.dat","r");
closegraph();
clrscr();
gotoxy(40,3);printf("order report");
gotoxy(1,4);printf("-----------------------------------------------------");
gotoxy(1,5);printf("order code
icode
vcode
vname
qty ");

44

gotoxy(1,6);printf("-----------------------------------------------------");
r=8;
while(fread(&order,sizeof(order),1,fp) !=0)
{
gotoxy(1,r);for(i=0;i<5;++i)
printf("%c",order.ocode[i]);
gotoxy(15,r);for(i=0;i<5;++i)
printf("%c",order.icode[i]);
gotoxy(24,r);for(i=0;i<5;++i)
printf("%c",order.vcode[i]);
gotoxy(34,r);for(i=0;i<20;++i)
printf("%c",order.vname[i]);
gotoxy(51,r);for(i=0;i<8;++i)
printf("%c",order.qty[i]);
if(r<=22)
r++;
else
{
gotoxy(2,22);printf("press any key to continue");
getche();
clrscr();
gotoxy(30,3);printf("ORDER REPORT");
gotoxy(1,4);printf("--------------------------------------------------------");
gotoxy(1,5);printf("order.code
icode
vcode
vname
qty
");
gotoxy(1,6);printf("--------------------------------------------------------");
r=10;
}
}
++r;
gotoxy(1,r);printf("---------------------------------------------------------");
getch();
}
vrep()
{

FILE *fp;
int r;
fp=fopen("vender.dat","r");
closegraph();
clrscr();
gotoxy(40,3);printf("**** VENDER REPORT ****");

gotoxy(1,4);printf("-------------------------------------------------------------------");
gotoxy(1,5);printf("vender code
vender name
vender add.
city
contactno. ");
gotoxy(1,6);printf("-------------------------------------------------------------------");
r=8;
while(fread(&vender,sizeof(vender),1,fp) !=0)
{
gotoxy(1,r);puts(vender.vcode);
gotoxy(15,r);puts(vender.vname);

45

gotoxy(32,r);puts(vender.adde);
gotoxy(47,r);puts(vender.city);
gotoxy(57,r);puts(vender.contno);
if(r<=22)
r++;
else
{

gotoxy(2,22);printf("press any key to continue");


getche();
clrscr();
gotoxy(30,3);printf("****VENDER REPORT****");

gotoxy(1,4);printf("--------------------------------------------------------------");
gotoxy(1,5);printf("
vender code
vender name
vender
add.
city
contactno");
gotoxy(1,6);printf("---------------------------------------------------------------");
r=8;
}
} ++r;
gotoxy(1,r);printf("------------------------------------------------------------------");
getche();
}
grep()
{
FILE *fp;
int r;
fp=fopen("order2.dat","r");
closegraph();
clrscr();
gotoxy(20,3);printf("**** GOOD RECEVING REPORT ****");
gotoxy(1,4);printf("-------------------------------------------------------------");
gotoxy(1,5);printf("order code
icode
vcode
qty
qtyr
qtyj
topay");
gotoxy(1,6);printf("--------------------------------------------------------------");
r=8;
while(fread(&order,sizeof(order),1,fp) !=0)
{
gotoxy(1,r);puts(order.ocode);
gotoxy(15,r);puts(order.icode);
gotoxy(24,r);puts(order.vcode);
gotoxy(32,r);puts(order.qty);
gotoxy(39,r);puts(order.qtyr);
gotoxy(48,r);puts(order.qtyj);
gotoxy(58,r);puts(order.topay);
if(r<=22)
r++;
else
{

46

gotoxy(2,22);printf("press any key to continue");


getche();
clrscr();
gotoxy(30,3);printf("****GOOD RECEVING REPORT");
gotoxy(1,4);printf("----------------------------------------------------------");
gotoxy(1,5);printf("order code
icode
vcode qty
qtyr
qtyj
topay ");
gotoxy(1,6);printf("----------------------------------------------------------");
r=10;
}
}
++r;
gotoxy(1,r);printf("------------------------------------------------------------");
getche();
}
prep()
{
FILE *fp;
int r,i;
fp=fopen("order1.dat","r");
closegraph();
clrscr();
gotoxy(20,3);printf("**** PAYMENT

REPORT ****");

gotoxy(1,4);printf("-------------------------------------------------------------------");
gotoxy(1,5);printf("icode
vcode
qty
qtyr
qtyj
topay
topaid
");
gotoxy(1,6);printf("--------------------------------------------------------------------");
r=8;
while(fread(&order1,sizeof(order1),1,fp) !=0)
{
gotoxy(1,r);for(i=0;i<5;++i)
printf("%c",order1.icode[i]);
gotoxy(10,r);for(i=0;i<5;++i)
printf("%c",order1.vcode[i]);
gotoxy(19,r);for(i=0;i<8;++i)
printf("%c",order1.qty[i]);
gotoxy(26,r);for(i=0;i<5;++i)
printf("%c",order1.qtyr[i]);
gotoxy(33,r);for(i=0;i<5;++i)
printf("%c",order1.qtyj[i]);
gotoxy(41,r);for(i=0;i<5;++i)
printf("%c",order1.topay[i]);
gotoxy(51,r);for(i=0;i<5;++i)
printf("%c",order1.topaid[i]);

if(r<=22)
r++;

47

else
{
gotoxy(2,22);printf("press any key to continue");
getch();
clrscr();
gotoxy(30,3);printf("**** PAYMENT REPORT****");
gotoxy(1,4);printf("--------------------------------------------------------");
gotoxy(1,5);printf("icode
vcode
qty
qtyr
qtyj
topay
topaid");
gotoxy(1,6);printf("-------------------------------------------------------");
r=10;
}
}
++r;
gotoxy(1,r);printf("------------------------------------------------------");
getche();
}

LIMITATIONS OF
THE PROJECT

48

LIMITATIONS OF THE PROJECT

1.

It does not display the code list itself.

2.

It does not display the Good menu of purchase with


amount.

3.

It does not provide sales menu respect to company


name.

4.

It works on GIGO concept.

5.

No user security options such as password are given.

6.

Unable to share data on multi user plateform.

49

FURTHER SCOPE

50

FURTHER SCOPE
A development never ever can be fully summarized or
concluded. Still I will try my beset to conclude all the
concepts regarding my project.
1.

It can be further connected with tax calculation still it


provides major head of expenses and income to
calculate net income.

2.

It can be further connected with detailed stock of


goods.

3.

It can be further connected with vb and this can be


converted into vb from C for the better designing.

51

REFERENCES

52

REFERENCES

For the completion of this project, I have taken help from the
following books:
1.
2
3

Programming with C
Let us C

by Dennice Ritche
by Yashwant Kanitkar
by Dr. R.S. Gupta

Business management

B.D. Sharma
N.S. Bhalla

53

You might also like