Project Repor Purchase Order System Doc
Project Repor Purchase Order System Doc
PROJECT REPORT
ON
PURCHASE ORDER SYSTEM
Submitted to the
The Degree of
Bachelor of Commerce
(Computer Application)
1
CERTIFICATE
CONTENTS
Certificate
Acknowledgement
Preface
2
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
3
INTRODUCTION
TO
PROBLEM AREA
4
INTRODUCTION TO PROBLEM AREA
data is mainly stored in the main menu file. This file is further
Through the quit entry we can come out from the main menu.
5
EXISTING SYSTEM
6
EXISTING SYSTEM
goods the first entries made at the gate and for this a
The goods are passed to the store and the entry of the
some time not accurate . also there can not be done any
comparative study.
7
LIMITATION OF EXISTING SYSTEM
8
LIMITATION OF EXISTING SYSTEM
of hardworking.
difficult.
now a days.
9
PROPOSED SYSTEM
10
PROPOSED SYSTEM
stores and then the bill are recorded in the store incoming
11
ADVANTAGES OF PROPOSED SYSTEM
12
ADVANTAGES OF PROPOSED SYSTEM
13
SYSTEM ANALYSIS
AND
DESIGNING
14
SYSTEM ANALYSIS
business.
runs
15
Inventory means lock up of capital of an enterprise.
service.
seen.
1 FIXED
2 PROBALISTIC
A) ABC ANALYSIS:
B) MIN-MAX SYSTEM:
16
For each type of Inventory minimum level is set that
INVENTORY RISKS:
1 Price Decline:
17
supply remains same and there is decrease in the general
market demand.
2 Product Deterioration:
3 Obsolescence:
18
SYSTEM DESIGNING
Main Menu
P PRODUCT MASTER
O ORDER PLACEMENT
V VENDOR MASTER
I ISSUE MASTER
Q REPORT MASTER
E EXIT
When first option is selected then Received Material Menu will be displayed
with data entry regarding purchases of new goods.
19
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.
2 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.
4 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
M ISSUE MODIFY ENTRY
Q ISSUE QUERY ENTRY
20
X 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];
21
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.
22
CODING
23
/* 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();
24
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");
25
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)
26
{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");
switch(ch4)
{case 'I':irep();break;
case 'V':vrep();break;
case 'O':orep();break;
case 'G':grep();break;
case 'A':prep();break;
27
case 'X':break;
}
if(ch4=='X')
break;
}
}
entry()
{char ch='Y',res;
int i,n;
FILE * fp;
fp=fopen("[Link]","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([Link]);
gotoxy(38,8);gets([Link]);
gotoxy(38,9);gets([Link]);
gotoxy(38,10);gets([Link]);
gotoxy(38,11);gets([Link]);
gotoxy(38,12);gets([Link]);
gotoxy(38,13);gets([Link]);
gotoxy(38,14);gets([Link]);
gotoxy(20,15);printf("Entries Correct Y/N");
res=getch();
if(toupper(res)=='Y')
{ for(i=0;i<=4;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=19;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=19;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=2;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=4;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=4;++i)
[Link][i]=toupper([Link][i]);
28
for(i=0;i<=4;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=4;++i)
[Link][i]=toupper([Link][i]);
n=strlen([Link]);
con([Link],n,5);
n=strlen([Link]);
con([Link],n,20);
n=strlen([Link]);
con([Link],n,20);
n=strlen([Link]);
con([Link],n,3);
n=strlen([Link]);
con([Link],n,5);
n=strlen([Link]);
con([Link],n,5);
n=strlen([Link]);
con([Link],n,5);
n=strlen([Link]);
con([Link],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("[Link]","r+");
while(toupper(ch)=='Y')
{ closegraph();
clrscr();
rewind(fp);
gotoxy(10,5);printf(" *** DATA MODIFICATION MODULE ***");
gotoxy(10,7);printf(" CODE OF PRODUCT ");
29
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([Link],mpcode,n)==1)
{++count;
gotoxy(38,8);for(i=0;i<20;++i)
printf("%c",[Link][i]);
gotoxy(38,9);for(i=0;i<20;++i)
printf("%c",[Link][i]);
gotoxy(38,10);for(i=0;i<3;++i)
printf("%c",[Link][i]);
gotoxy(38,11);for(i=0;i<5;++i)
printf("%c",[Link][i]);
gotoxy(38,12);for(i=0;i<5;++i)
printf("%c",[Link][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([Link]);
con([Link],n,20);
n=strlen([Link]);
con([Link],n,20);
n=strlen([Link]);
con([Link],n,3);
n=strlen([Link]);
con([Link],n,5);
n=strlen([Link]);
con([Link],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()
30
{ char ch='Y',res;
char mpcode[5];
int i,n,count=0;
FILE *fp;
fp=fopen("[Link]","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([Link],mpcode,n)==1)
{ ++count;
gotoxy(38,8);for(i=0;i<20;++i)
printf("%c",[Link][i]);
gotoxy(38,9);for(i=0;i<20;++i)
printf("%c",[Link][i]);
gotoxy(38,10);for(i=0;i<3;++i)
printf("%c",[Link][i]);
gotoxy(38,11);for(i=0;i<5;++i)
printf("%c",[Link][i]);
gotoxy(38,12);for(i=0;i<5;++i)
printf("%c",[Link][i]);
}
if(count==0)
oentry()
{
char ch='Y',res;
int i;
FILE *fp;
fp=fopen("[Link]","ar+");
while(toupper(ch)=='Y')
{closegraph();
clrscr();
31
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([Link]);
gotoxy(38,8);gets([Link]);
gotoxy(38,9);gets([Link]);
gotoxy(38,10);gets([Link]);
gotoxy(38,11);gets([Link]);
gotoxy(20,15);printf("Entries Correct Y/N");
res=getch();
if(toupper(res)=='Y')
{// clrscr();
for(i=0;i<=4;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=4;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=4;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=19;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=7;++i)
[Link][i]=toupper([Link][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("[Link]","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([Link],mocode,n)==1)
{++count;
32
gotoxy(38,8);for(i=0;i<5;++i)
printf("%c",[Link][i]);
gotoxy(38,9);for(i=0;i<5;++i)
printf("%c",[Link][i]);
gotoxy(38,10);for(i=0;i<20;++i)
printf("%c",[Link][i]);
gotoxy(38,11);for(i=0;i<8;++i)
printf("%c",[Link][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([Link]);
con([Link],n,5);
n=strlen([Link]);
con([Link],n,5);
n=strlen([Link]);
con([Link],n,20);
n=strlen([Link]);
con([Link],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("[Link]","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)
33
n=strlen(mocode);
if(scom([Link],mocode,n)==1)
{ ++count;
gotoxy(38,8);for(i=0;i<8;++i)
printf("%c",[Link][i]);
gotoxy(38,9);for(i=0;i<5;++i)
printf("%c",[Link][i]);
gotoxy(38,10);for(i=0;i<5;++i)
printf("%c",[Link][i]);
gotoxy(38,11);for(i=0;i<20;++i)
printf("%c",[Link][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("[Link]","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([Link]);
gotoxy(38,8);gets([Link]);
gotoxy(38,9);gets([Link]);
gotoxy(38,10);gets([Link]);
gotoxy(38,11);gets([Link]);
gotoxy(38,12);gets([Link]);
gotoxy(20,15);printf("Entries Correct Y/N");
res=getch();
if(toupper(res)=='Y')
{for(i=0;i<=4;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=19;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=19;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=14;++i)
[Link][i]=toupper([Link][i]);
34
for(i=0;i<=9;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=14;++i)
[Link][i]=toupper([Link][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("[Link]","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([Link],mvcode,n)==1)
{++count;
gotoxy(38,8);puts([Link]);
gotoxy(38,9);puts([Link]);
gotoxy(38,10);puts([Link]);
gotoxy(38,11);puts([Link]);
gotoxy(38,12);puts([Link]);
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);
35
}
}
}
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("[Link]","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([Link],mvcode)==0)
{ ++count;
gotoxy(38,8);puts([Link]);
gotoxy(38,9);puts([Link]);
gotoxy(38,10);puts([Link]);
gotoxy(38,11);puts([Link]);
gotoxy(38,12);puts([Link]);
}
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;
36
FILE *fp;
fp=fopen("[Link]","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([Link]);
gotoxy(40,8);gets([Link]);
gotoxy(40,9);gets([Link]);
gotoxy(40,10);gets([Link]);
gotoxy(40,11);gets([Link]);
gotoxy(40,12);gets([Link]);
gotoxy(40,13);gets([Link]);
gotoxy(40,14);gets([Link]);
gotoxy(20,17);printf("Entries Correct Y/N");
res=getch();
if(toupper(res)=='Y')
{
for(i=0;i<=4;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=4;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=4;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=4;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=4;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=4;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=4;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=4;++i)
[Link][i]=toupper([Link][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("[Link]","ar+");
while(toupper(ch)=='Y')
{ closegraph();
clrscr();
37
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([Link]);
gotoxy(38,8);gets([Link]);
gotoxy(38,9);gets([Link]);
gotoxy(38,10);gets([Link]);
gotoxy(38,11);gets([Link]);
gotoxy(40,12);gets([Link]);
gotoxy(40,13);gets([Link]);
gotoxy(20,17);printf("Entries Correct Y/N");
res=getch();
if(toupper(res)=='Y')
{
for(i=0;i<=4;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=4;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=4;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=4;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=4;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=4;++i)
[Link][i]=toupper([Link][i]);
for(i=0;i<=4;++i)
[Link][i]=toupper([Link][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("[Link]","r");
closegraph();
clrscr();
gotoxy(40,3);printf("****STOCK REPORT****");
gotoxy(1,4);printf("---------------------------------------------------
-------------");
gotoxy(1,5);printf("[Link] prodname max qty min
");
gotoxy(1,6);printf("___________________________________________________
_____________");
r=8;
38
while(fread(&product,sizeof(product),1,fp) !=0)
{
gotoxy(1,r);for(i=0;i<5;++i)
printf("%c",[Link][i]);
gotoxy(16,r);for(i=0;i<20;++i)
printf("%c",[Link][i]);
gotoxy(30,r);for(i=0;i<5;++i)
printf("%c",[Link][i]);
gotoxy(39,r);for(i=0;i<5;++i)
printf("%c",[Link][i]);
gotoxy(47,r);for(i=0;i<5;++i)
printf("%c",[Link][i]);
gotoxy(60,r);
if(atoi([Link])>atoi([Link]))
printf("Above");
else
{ if(atoi([Link])>=atoi([Link]))
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("[Link] 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("[Link]","r");
closegraph();
clrscr();
gotoxy(40,3);printf("order report");
gotoxy(1,4);printf("---------------------------------------------------
---");
gotoxy(1,5);printf("order code icode vcode vname
qty ");
39
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",[Link][i]);
gotoxy(15,r);for(i=0;i<5;++i)
printf("%c",[Link][i]);
gotoxy(24,r);for(i=0;i<5;++i)
printf("%c",[Link][i]);
gotoxy(34,r);for(i=0;i<20;++i)
printf("%c",[Link][i]);
gotoxy(51,r);for(i=0;i<8;++i)
printf("%c",[Link][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("[Link] icode vcode vname
qty ");
gotoxy(1,6);printf("---------------------------------------------------
------");
r=10;
}
} ++r;
gotoxy(1,r);printf("---------------------------------------------------
-------");
getch();
}
vrep()
{
FILE *fp;
int r;
fp=fopen("[Link]","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([Link]);
gotoxy(15,r);puts([Link]);
40
gotoxy(32,r);puts([Link]);
gotoxy(47,r);puts([Link]);
gotoxy(57,r);puts([Link]);
if(r<=22)
r++;
else
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("[Link]","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([Link]);
gotoxy(15,r);puts([Link]);
gotoxy(24,r);puts([Link]);
gotoxy(32,r);puts([Link]);
gotoxy(39,r);puts([Link]);
gotoxy(48,r);puts([Link]);
gotoxy(58,r);puts([Link]);
if(r<=22)
r++;
else
{
41
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("[Link]","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",[Link][i]);
gotoxy(10,r);for(i=0;i<5;++i)
printf("%c",[Link][i]);
gotoxy(19,r);for(i=0;i<8;++i)
printf("%c",[Link][i]);
gotoxy(26,r);for(i=0;i<5;++i)
printf("%c",[Link][i]);
gotoxy(33,r);for(i=0;i<5;++i)
printf("%c",[Link][i]);
gotoxy(41,r);for(i=0;i<5;++i)
printf("%c",[Link][i]);
gotoxy(51,r);for(i=0;i<5;++i)
printf("%c",[Link][i]);
if(r<=22)
r++;
42
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
43
LIMITATIONS OF THE PROJECT
44
FURTHER SCOPE
45
FURTHER SCOPE
46
REFERENCES
47
REFERENCES
For the completion of this project, I have taken help from the
following books:
48