C++ PROJECT 2012-2013 C++ PROJECT 2012-2013C++PROJECT   C++ PROJECT         C++ PROJECT    C++ PROJECTC++ PROJECT    C++ P...
Moviereservation          2
                              KASTURBAENGLISH MEDIUM SENIOR SECONDARY SCHOOL                Affiliated to CBSE, New Delhi...
                        KASTURBA  ENGLISH MEDIUM SENIOR SECONDARY SCHOOL            Affiliated to CBSE, New Delhi, Aff. N...
   INDEX 1.ACKNOWLEDGEMENT 2.AIM 3. APPARATUS 4. FLOW CHART 5. PROGRAM DESCRIPTION 6. PROGRAM CODE7. OUTPUT8.BIBI...
 ACKNOWLEDGEMENT     I Would Like To Express My Deep Sense Of Gratitude To    All Those Who Have Helped Me In Completing ...
This is a program done in C++ language to reserve a movie ticket by usersfrom a list of movies which are managed by the ad...
HARDWARE:-     LOGITECH MOUSE     LOGITECH KEYBOARD     HP PRINTER     INTEL DUAL CORE     LCD MONITORSOFTWARE:-   W...
STARTm1             9
WELCOME SCREEN             MAIN             MENU                                         ADMIN (‘A’)                      ...
TRUE                                                      MODIFY(‘M’)                                                     ...
ADD MOVIES(‘A’)                                                 EDIT MOVIES(‘E’)If Choice==                         MODIFY...
ADD MOVIESif choice==                                                       a3  ‘a’||’A’      TRUE                   MT.TX...
If choice==               TRUE   BOOK MOVIE  ‘b’||’B’                                              MB.TXT         u1      ...
If choice===   TRUE    EXIT                                EXIT ‘e’||’E’              SCREENIf choice===            m1    ...
This is a user friendly and menu drivenprogram which is designed to book ticketsfor a movie by the user by providing thene...
 Settings („S‟)  See booking list („B‟)  Exit as admin („E‟)The “modify movies” option has a menu ofadding movies, dele...
details. The total fare is calculated and isshown along with the main ticket number.The program is a very interactive andi...
/*******  T H E A T H T R E   M A N A G E M E N T   P R O J E C T    ****** Done By: G Rajesh 12th Science   2012-2013Kast...
class admin              //Class Defined for Administration Module{public:char mname[30];void admn();void result();protect...
int uno;char uphone[20];int utc;char mov[30];public:void showbooked();void tcallote();void umenu();void uedit();void ucanc...
delay(30);gotoxy(2+i,1);cputs("═");if(i<20){gotoxy(1,i+2);cputs("║");}if(i==20){gotoxy(1,22);cputs("╚");}if(i>20){gotoxy(x...
textcolor(12);gotoxy(3,3);cputs("╔");for(i=0;i<75;i++){cputs("═");}for(i=4;i<21;i++){gotoxy(3,i);cputs("║");}gotoxy(3,20);...
gotoxy(27,9);cout<<" "<<c;gotoxy(27,10);cout<<" "<<c;gotoxy(27,11);cout<<" "<<c;gotoxy(27,12);for(i=0;i<5;i++)cout<<c;dela...
n=2;for(int j=0;j<8;j++){delay(30);gotoxy(x,y);cout<<users[i];y--;gotoxy(x,y+2);cout<<" ";gotoxy(m,n);cout<<admins[i];n++;...
{delay(20);gotoxy(1,y);cout<<ch;gotoxy(80,y);cout<<ch;y++;}}gotoxy(1,21);cout<<" ";gotoxy(2,21);cout<<" ";gotoxy(16,4);int...
cputs("n             _/_/_/_/_/ _/                            _/");cout<<endl;cputs("                 _/       _/_/_/     ...
if(apass[j]==r)break;cout<<"*";}apass[j]=0;cout<<"nChecking Username and Password Combination ";for(int che=0;che<7;che++)...
goto ex;textcolor(aj);textbackground(ai);clrscr();cout<<"nt                           ADMINS MENUn"<<endl;delay(500);gotox...
p1=1;a.admn();}else if(c1==m||c1==M){a.modify();}else if(c1==E||c1==e){ex:goto g;}else if(c1==b||c1==B){cout<<"nBooking Li...
c2=getche();gotoxy(30,15);if(c2==a||c2==A){add();}else if(c2==m||c2==M){edit();}else if(c2==d||c2==D){del();}else if(c2==e...
}cout<<"tt╔════════════════════════╗ "<<endl;cout<<"tt║number:color            ║ "<<endl;cout<<"tt║                       ...
gets(mname);cout<<"Language "<<endl;gets(mlang);cout<<"Rating "<<endl;cin>>mstars;cout<<"Description "<<endl;gets(mdes);co...
if(r==0)goto k;i=0;fin.seekp(0);while(fin){i++;pos=fin.tellg();fin.read((char*)&a,sizeof(a));if(i==r){cout<<"Movie Foundn ...
delay(300);modify();}fout.open("mt.txt",ios::in);cout<<"Now The Movies are.. :n"<<endl;delay(500);fout.seekg(0);clrscr();w...
gotoxy(1,30);}void admin::del()    //To Delete A Movie From List{p=0;i=0;r=0;fout.open("mt.txt",ios::in);fout.seekg(0);i=0...
remove("mt.txt");rename("temp.txt","mt.txt");fin.open("mt.txt",ios::in);cout<<"Now The Movies are :"<<endl;delay(900);clrs...
cout<<"Enter The No of seats for the movie"<<endl;cin>>nseats;delay(300);cout<<"Initialising tickets with 0"<<endl;mseats=...
delay(500);cout<<" = Rs.";delay(900);float q;q=mprice*(c3);cout<<q<<endl;break;}}file.close();} //End Of Functions Definit...
cout<<"             ";}else{x-- ;gotoxy(70-x,20);delay(70);cout<<modi;gotoxy(69-x,20);cout<<" ";delay(70);gotoxy(x,20);cou...
if(r==0){cout<<"Returning.."<<char(24)<<endl;delay(1800);clrscr();goto z;}i=0;fin.open("mt.txt",ios::in);while(fin.read((c...
cout<<"Enter Your name "<<endl;gets(uname);cout<<"Enter your age "<<endl;cin>>uage;cout<<"Enter the no. of tickets to be b...
if(strcmp(a.mname,name)==0){tics=a.tick;while(cnt>0){tics++;cnt--;cout<<tics<<endl;delay(300);}break;}}f1.close();u.utc=ti...
cout<<"Movie :"<<u.mov<<endl;strcpy(name,u.mov);cout<<"CANCEL BOOKING????"<<endl;c2=getche();if(c2==n||c2==N)fout.write((c...
cout<<"Movie Selected :"<<name;}}f1.close();float pos;int t;p=0;cout<<"nModify Your Booking "<<endl;fout.open("mb.txt",ios...
a.seatmanage((n-i));if(n>i)a.seatmanage((i-n));delay(300);cout<<"Details Saved"<<endl;}cout<<"Press Any Key"<<endl;getch()...
 OUTPUTWelcome screens                  47
48
if choice = ‘a’(admin module)                                49
if choice=’m’(modify menu) if choice=’a’(add movies)if choice=’d’(delete movies)                                          ...
Back to Admins menu & choice==’a’(movies running)back to admin’s menu &choice=’s’(settings)                               ...
Back to welcome screenuser’s menu                         52
if choice=’b’(book movies)                             53
if choice==’c’(cancelling booking)if choice=’e’(exit as user)                                     54
Exit screen              55
 Bibliography www.cplusplus.com Help menu on turbo c++ Computer science with c++ (12th class text)                    ...
Thank you            57
58
Upcoming SlideShare
Loading in...5
×

c++ report file for theatre management project

8,058

Published on

its a project report for theatre management project done in c++ language without graphics.h

Published in: Education
0 Comments
8 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
8,058
On Slideshare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
731
Comments
0
Likes
8
Embeds 0
No embeds

No notes for slide

c++ report file for theatre management project

  1. 1. C++ PROJECT 2012-2013 C++ PROJECT 2012-2013C++PROJECT C++ PROJECT C++ PROJECT C++ PROJECTC++ PROJECT C++ PROJECT C++ PROJECT C++PROJECT C++ PROJECT C++ PROJECT C++ PROJECTC++ PROJECT C++ PROJECT C++ PROJECT C++PROJECT C++ PROJECT C++ PROJECT C++ PROJECTC++ PROJECT C++ PROJECT C++ PROJECT C++PROJECT C++ PROJECT C++ PROJECT C++ PROJECT C++ PROJECTC++ PROJECT REPORT C++ PROJECT C++ PROJECT C++PROJECT C++ PROJECT 2012-2013 C++ PROJECT C++ PROJECTC++ PROJECT C++ PROJECT C++ PROJECT C++PROJECT C++ PROJECT C++ PROJECT C++ PROJECT DONE BY :G RAJESHC++ PROJECT C++ PROJECT C++ PROJECT C++ 12TH APROJECT C++ PROJECT C++ PROJECT C++ PROJECT C++ KASTURBA ENGLISH MEDIUM SCHOOL ,PROJECT C++MANJUMMEL C++ PROJECT C++ PROJECT C++ PROJECTPROJECT C++ PROJECT C++ PROJECT C++ PROJECT C++PROJECT C++TOPIC:THEATRE MANAGEMENT C++ PROJECT C++ PROJECT C++ PROJECTPROJECT C++ PROJECT C++ PROJECT C++ PROJECTC++PROJECT C++ PROJECT C++ PROJECT C++ PROJECTC++PROJECT C++ PROJECT C++ PROJECT C++ PROJECTC++PROJECT C++ PROJECT C++ PROJECT C++ PROJECTC++PROJECT C++ PROJECT C++ PROJECT C++ PROJECTC++PROJECT C++ PROJECT C++ PROJECT C++ PROJECTC++PROJECT C++ PROJECT C++ PROJECT C++ PROJECTC++PROJECT C++ PROJECT C++ PROJECT C++ PROJECTC++PROJECT C++ PROJECT C++ PROJECT C++ PROJECT 1C++PROJECT C++ PROJECT C++ PROJECT C++ PROJECT 1C++PROJECT C++ PROJECT C++ PROJECT C++ PROJECT
  2. 2. Moviereservation 2
  3. 3.  KASTURBAENGLISH MEDIUM SENIOR SECONDARY SCHOOL Affiliated to CBSE, New Delhi, Aff. No. : 930463 Report on the Computer ProjectName : G RAJESHStandard : XII ScienceProject Guide : Aravind LakshmanProject : MOVIE RESERVATION Certified that this is the bonafide report of the projectwork of G Rajesh in this school submitted for the practicalexamination held in 2013, Kasturba School, Manjummel.Examiner Project Guide Principal 3
  4. 4.  KASTURBA ENGLISH MEDIUM SENIOR SECONDARY SCHOOL Affiliated to CBSE, New Delhi, Aff. No. : 930463 Bonafide Certificate I certify that G Rajesh Student of Computer Sciencestudying in Std XII, Kasturba Senior Secondary School,Manjummel has successfully completed the project“MOVIE RESERVATION” under my guidance during the year2012-2013 Project Guide 4
  5. 5.  INDEX 1.ACKNOWLEDGEMENT 2.AIM 3. APPARATUS 4. FLOW CHART 5. PROGRAM DESCRIPTION 6. PROGRAM CODE7. OUTPUT8.BIBILIOGRAPHY 5
  6. 6.  ACKNOWLEDGEMENT I Would Like To Express My Deep Sense Of Gratitude To All Those Who Have Helped Me In Completing This Project. I Specially Thank Our Sir Aravind Lakshman WhoGave Me All Guidance To Complete My Project Work Successfully. Apart From It, I Acknowledge My Parents, Groupmembers And All Others Who Helped Me For Completing ThisGreat Task. Above All I Thank The Almighty God For MakingThis Project A Great Success.  AIM 6
  7. 7. This is a program done in C++ language to reserve a movie ticket by usersfrom a list of movies which are managed by the administrator.The user must provide his name and other details to book his/her desiredmovie in the list.  APPARATUS 7
  8. 8. HARDWARE:-  LOGITECH MOUSE  LOGITECH KEYBOARD  HP PRINTER  INTEL DUAL CORE  LCD MONITORSOFTWARE:-  WINDOWS XP  TURBO C++  MS DOS  MS WORD FLOW CHART 8
  9. 9. STARTm1 9
  10. 10. WELCOME SCREEN MAIN MENU ADMIN (‘A’) USER (‘U’) A A If PASSWORD Choice== TRUE AND USERNAME FALSE EXIT ’a’||’a’ a1 TRUE TICKET INITIALISE(‘T’) MOVIE LIST(‘A’) ADMIN MENU MODIFY MENU(‘M’ SETTINGS(‘S’) BOOKING LIST(‘B’) ach EXIT(‘E’) BOOK(‘B’) CANCEL(‘C’) USER MENUIf choice !=’U’ 10&& !=’A’
  11. 11. TRUE MODIFY(‘M’) EXIT AS USER(‘E’) ELSE EXIT(‘E’) mch SWITCH(‘S’) m2 ach a1 TICKETS INITIALISEIf Choice== ’t’||’T’ TRUE TC.TXT a3 a1If Choice== DISPLAY ALL MOVIE’S DETAILS ’a’||’A’ TRUE MT.TXT a2 11
  12. 12. ADD MOVIES(‘A’) EDIT MOVIES(‘E’)If Choice== MODIFYING ’m’||’M’ MENU TRUE MODIFY MOVIES(‘M’) EXIT MODIYING(‘E’) ach 2 READ CHOICE a1If Choice== BOOKING LIST ’b’||’B’ TRUE MB.TXTIf Choice== COLOUR SETTINGS m1 ’s’||’S’ TRUEIf Choice== m2 ’e’||’E’ TRUE a1 ELSE ach 2 12
  13. 13. ADD MOVIESif choice== a3 ‘a’||’A’ TRUE MT.TXTIf choice== MODIFY MOVIE a3 ‘m’||’M’ TRUE MT.TXT If choice== ‘d’||’D’ TRUE DELETE MOVIE a3 MT.TXT If choice== a1 TRUE ‘e’||’E’ a2 ELSEuch u1 13
  14. 14. If choice== TRUE BOOK MOVIE ‘b’||’B’ MB.TXT u1 DETAILS u1 MB.TXT If choice== TRUE CANCEL BOOKING TRUE ‘c’||’C’ FALSE u1 TICKET NUMBER u1 MB.TXT If choice== TRUE MODIFY BOOKING TRUE ‘m’||’M’ FALSE u1 TICKET NUMBERIf choice=== TRUE m2 ‘e’||’E’ ELSE u1 mch 14
  15. 15. If choice=== TRUE EXIT EXIT ‘e’||’E’ SCREENIf choice=== m1 TRUE ‘s’||’S’ PROGRAM DESCRIPTION 15
  16. 16. This is a user friendly and menu drivenprogram which is designed to book ticketsfor a movie by the user by providing thenecessary details.......When the program is executed ,the welcomescreen appears showing the logo of thetheatre‟s name and then shows the option toenter as an admin or a user.The Admin menu is accessible only afterproviding the right username and passwordcombination within 3 chances.  The admin module has 6 options :  Initialise tickets („T‟)  Movies running („A‟)  Modify movies („M‟) 16
  17. 17.  Settings („S‟)  See booking list („B‟)  Exit as admin („E‟)The “modify movies” option has a menu ofadding movies, deleting current movies andediting the current movie details.The option “settings” deals with customizingthe background colour and text colour.The user menu has a simple menu containingthe options:  Book a movie(„B‟)  Modify a booking(„M‟)  Cancel a booking(„B‟)  Exit as user(„E‟)When the “book a movie” option is selectedthe list of all movies running in the theatre isshown. The user has to select a movie andthen enter his/her details like name, age,number of tickets to be booked and contact 17
  18. 18. details. The total fare is calculated and isshown along with the main ticket number.The program is a very interactive andinteresting with colourful texts and colouredbackground for each module making it veryclose to real life booking of movie tickets ason internet....  PROGRAM CODE 18
  19. 19. /******* T H E A T H T R E M A N A G E M E N T P R O J E C T ****** Done By: G Rajesh 12th Science 2012-2013Kasturba English Medium SchoolManjummel */#include<iostream.h> //For Basic Input/output Operations#include<fstream.h> //For File Handling Operations#include<conio.h> //For getch() & clrscr() Functions#include<dos.h> //For delay() function#include<stdio.h> //For gets(),puts(),remove()& rename()..#include<string.h> //For strcmp() ,strcpy() Functions#include<process.h> //For Exit() Function#include<time.h> //For displaying time in user moduleint mi=0;int mj=10;int ai=0;int aj=11;int ui=8;int uj=9;char ch,c1,c2,name[30]; //G L O B A L V A R I A B L E Sint i,p,p1,r; // used throughout the programlong pos;char aname[20],apass[20];fstream fin,fout,file; //G L O B A L F I L E P O I N T E RS 19
  20. 20. class admin //Class Defined for Administration Module{public:char mname[30];void admn();void result();protected:char mlang[20];char mdes[50];int mstars;char mactors[30];char mdirector[20];float mprice;char mcbfc[5];char mtiming[20];private:void tcrun();void edit();void modify();void del();void add();void settings();public:void seatmanage(int);void amtcal(int);int mseats;int tick;admin() // Constructor for class admin{strcpy(mname,"<no name>");strcpy(mlang,"<no info>");strcpy(mdes,"<no info>");strcpy(mactors,"<no info>");strcpy(mdirector,"<no info>");strcpy(mcbfc,"n/a");mstars=0;tick=0;mseats=0;}void showseats(){if(mseats>0)cout<<mseats;else{textcolor(0);cout<<"HOUSE FULL!!!";}}}a;class user:protected admin //Class for User Module ProtectedlyInherited from class Admin{private:char uname[30];int uage; 20
  21. 21. int uno;char uphone[20];int utc;char mov[30];public:void showbooked();void tcallote();void umenu();void uedit();void ucancel();void ubooking();user(){strcpy(uname,"empty ");uage=0;uno=0;utc=0;strcpy(uphone,"n/a");}protected:}u;void main(){clrscr();int j,k;gotoxy(24,19);cout<<"L O A D I N G P R O J E C T F I L E "<<endl;gotoxy(28,22);cout<<"___________";j=28;for(int i=0;i<101;i++){gotoxy(41,22);delay(50);cout<<i<<"% completed"<<endl;if(i%10==0){gotoxy(j,22);j++;cout<<char(16);}}cout<<"nnttttSUCCESSFULLY LOADED" <<endl;c1=s;while(c1==s||c1==S){delay(500);textbackground(mi);textcolor(mj);clrscr();int i,x=1;cout<<"╔";delay(100);for(i=0;i<78;i++){ 21
  22. 22. delay(30);gotoxy(2+i,1);cputs("═");if(i<20){gotoxy(1,i+2);cputs("║");}if(i==20){gotoxy(1,22);cputs("╚");}if(i>20){gotoxy(x+1,22);cputs("═");x++;}}delay(50);gotoxy(80,1);cputs("╗");for(i=0;i<22;i++){delay(30);if(i<20){gotoxy(80,2+i);cputs("║");}gotoxy(x+i,22);cputs("═");if(i==19){gotoxy(80,22);cputs("╝") ;}}delay(700);textcolor(14);gotoxy(2,2);cputs("╔");for(i=0;i<76;i++){cputs("═");}for(i=3;i<21;i++){gotoxy(2,i);cputs("║");}gotoxy(2,21);cputs("╚");for(i=3;i<79;i++){gotoxy(i,21);cputs("═");}cputs("╝") ;for(i=20;i>2;i--){gotoxy(79,i);cputs("║");}gotoxy(79,2);cputs("╗");delay(700); 22
  23. 23. textcolor(12);gotoxy(3,3);cputs("╔");for(i=0;i<75;i++){cputs("═");}for(i=4;i<21;i++){gotoxy(3,i);cputs("║");}gotoxy(3,20);cputs("╚");for(i=4;i<78;i++){gotoxy(i,20);cputs("═");}cputs("╝") ;for(i=19;i>3;i--){gotoxy(78,i);cputs("║");}gotoxy(78,3);cputs("╗");x=59;int y=10;char c=char(15);for(i=10;i<60;i++){delay(50);gotoxy(i,10);cout<<c;gotoxy(i-1,10);cout<<" ";}for(i=0;i<6;i++){delay(100);gotoxy((x-i),(y-i));cout<<c;gotoxy((x+i),(y+i));cout<<c;gotoxy((x+i),(y-i));cout<<c;gotoxy((x-i),(y+i));cout<<c;}int m=x+5,n=x-5;for(i=0;i<40;i++){delay(60);if(i<13){gotoxy(m+i,y+5);cout<<c;gotoxy(m+i,y-5);cout<<c;}gotoxy((n-i),y+5);cout<<c;gotoxy((n-i),y-5);cout<<c;}delay(200);gotoxy(27,8);for(i=0;i<5;i++)cout<<c; 23
  24. 24. gotoxy(27,9);cout<<" "<<c;gotoxy(27,10);cout<<" "<<c;gotoxy(27,11);cout<<" "<<c;gotoxy(27,12);for(i=0;i<5;i++)cout<<c;delay(200);gotoxy(37,8);cout<<c<<" "<<c;gotoxy(37,9);cout<<c<<" "<<c<<" "<<c<<" "<<c;gotoxy(37,10);cout<<c<<" "<<c<<" "<<c;gotoxy(37,11);cout<<c<<" "<<c;gotoxy(37,12);cout<<c<<" "<<c;delay(200);gotoxy(46,8); cout<<" "<<c;gotoxy(46,9); cout<<" "<<c<<" "<<c;gotoxy(46,10);cout<<" "<<c<<c<<c<<c<<c;gotoxy(46,11);cout<<" "<<c<<" "<<c;gotoxy(46,12);cout<<c<<" "<<c;char temp[]={"IMAX::ENTERTAINMENT UNLIMITED"};x=46;c=char(2);for(i=0;i<24;i++){delay(100);gotoxy(x-i,16);cout<<c<<temp<<c;gotoxy((x-i+31),16);cout<<" ";}delay(40);gotoxy(31,17);cout<<"PHC-2,Banglore"<<endl;delay(40);gotoxy(4,19);cout<<"www.etunlimited.com";gotoxy(65,19);cout<<"Ph:080-623311"<<endl;m=10;y=47;for(i=0;i<34;i++){m++;textcolor(m+8);textbackground(0);if(m==17)m=1;if(i%2==0)y--;delay(90);gotoxy(33,y); cputs(" PRESS ENTER ");delay(100);gotoxy(33,y+1);cputs(" ");}ch=getch();if(ch!=r)goto ex;textcolor(5);clrscr();m=30,n=2,x=30,y=20;char admins[]={"TO LOGIN AS ADMIN "A""};char users[]={"TO ENTER AS USER "U""};for(i=0;users[i]!=0;i++){x++;m++;y=20; 24
  25. 25. n=2;for(int j=0;j<8;j++){delay(30);gotoxy(x,y);cout<<users[i];y--;gotoxy(x,y+2);cout<<" ";gotoxy(m,n);cout<<admins[i];n++;gotoxy(m,n-2);cout<<" ";}cout<<" ";}cout<<"nnnttttt";ch=getche();if(ch==a||ch==A){a.admn();}else if(ch==u||ch==U){u.umenu();}else{cout<<"nWRONG CHOICE"<<endl;goto v;}p1=0;v:cout<<"nPress "e" to exit"<<endl;cout<<"Press "s" to switch to user or admin mode"<<endl;c1=getche();}if(c1==e||c1==E) //EXIT Module{ex:textbackground(0);textcolor(13);clrscr();int x=1,y=1;clrscr();ch=char(2);for(i=0;i<80;i++){gotoxy(x,1);delay(20);cout<<ch;gotoxy(x,20);cout<<ch;gotoxy(80-x,1) ;delay(20);cout<<ch;gotoxy(80-x,20);cout<<ch;x++;if(i<20) 25
  26. 26. {delay(20);gotoxy(1,y);cout<<ch;gotoxy(80,y);cout<<ch;y++;}}gotoxy(1,21);cout<<" ";gotoxy(2,21);cout<<" ";gotoxy(16,4);int j=28;char temp[40]={"THEATRE MANAG"};char tem[20]= {"TCEJORP TNEME"};for(j=0,i=0;i<13;i++){delay(100);gotoxy(30+i,4);cout <<temp[i];gotoxy(55-i,4);cout<<tem[j];j++;}gotoxy(3,10);cout<<"DONE BY ";gotoxy(50,13);strcpy(temp,"G RAJESH");x=50;for(i=0;i<40;i++){x--;delay(50);gotoxy(x,13);cout<<temp;gotoxy(x+8,13) ;cout<<" " ;}delay(800);gotoxy(10,14);cout<<"12th Science ";delay(100);gotoxy(10,15);cout<<"///////";gotoxy(10,17);delay(600);cout<<"KASTURBA ENGLISH MEDIUM SCHOOL, MANJUMMEL";delay(1000);for(i=0;i<110;i++){textcolor(i);delay(50);gotoxy(2,21);cout<<endl;cout<<"n"; 26
  27. 27. cputs("n _/_/_/_/_/ _/ _/");cout<<endl;cputs(" _/ _/_/_/ _/_/_/ _/_/_/ _/ _/");cout<<endl;cputs(" _/ _/ _/ _/ _/ _/ _/ _/_/");cout<<endl;cputs(" _/ _/ _/ _/ _/ _/ _/ _/ _/");cout<<endl;cputs(" _/ _/ _/ _/_/_/ _/ _/ _/_/");cout<<endl;cout<<"nnn";cputs(" _/ _/");cout<<endl;cputs(" _/ _/ _/_/_/_/ _/ _/");cout<<endl;cputs(" _/ _/ _/ _/ _/");cout<<endl;cputs(" _/ _/ _/ _/ _/");cout<<endl;cputs(" _/ _/_/_/_/ _/_/_/_/");cout<<endl;}cout<<"nnn Press any key to exit"<<endl;getch();cout<<"n Program Teriminated"<<endl;delay(500);exit(0);}getch();}void admin::admn(){char temp[]={"nnttW E L C O M E T O I M A X D A T A B A SE "};clrscr();textcolor(4);textbackground(0);clrscr();int j;if(p1==1)goto l;for(i=0;i<3;i++) //Checking Password & User NameCombination{delay(300);clrscr();cout<<"nttAUTHENTICATION REQUIRED"<<endl;cout<<"nUserName: "<<endl;cout<<"PassWord: "<<endl;gotoxy(10,4);gets(aname);gotoxy(10,5);for(j=0;j<20;j++){apass[j]=getch(); 27
  28. 28. if(apass[j]==r)break;cout<<"*";}apass[j]=0;cout<<"nChecking Username and Password Combination ";for(int che=0;che<7;che++){delay(300);cout<<".";}if((strcmp(aname,"raj32")==0)){if((strcmp(apass,"rgr2511")==0) ){p=1;break;}else{ p=0; cout<<"anWrong User Name and Pass Word combination"<<endl; if(i==2) { cout<<"nAUTHENTICATION FAILED!!!"<<endl; cout<<"nEXITING"<<endl; delay(900); exit(0); } else { cout<<"No. of chances remaining: "<<(2-i)<<endl; delay(900); }}}}if(p==1){clrscr();textcolor(10);clrscr();gotoxy(20,20);cout<<" L O G I N S U C C E S S F U L !!"<<endl; //Welcome ScreenFor Admindelay(1000);textcolor(14);clrscr();gotoxy(1,20);for(i=0;i<52;i++){delay(70);cout<<temp[i];}delay(800);l:if(i==3) 28
  29. 29. goto ex;textcolor(aj);textbackground(ai);clrscr();cout<<"nt ADMINS MENUn"<<endl;delay(500);gotoxy(46,7);cout<<""T" TICKET initialising";delay(500);gotoxy(52,13);cout<<""A"";cout<<" MOVIES running";delay(500);gotoxy(47,19);cout<<""M"";cout<<" MODIFY menu ";gotoxy(20,19);delay(500);cout<<"colour SETTINGS "S"";gotoxy(16,13);delay(500);cout<<"BOOKING list "B"";gotoxy(21,7);delay(500);cout<<"EXIT as ADMIN ";cout<<""E"";gotoxy(43,13);c1=getche();cout<<endl;clrscr();if(c1==t||c1==T){a.tcrun();}else if(c1==s||c1==S){settings();}else if(c1==a||c1==A){cout<<"nThe Movies Running In IMAX are :"<<endl;delay(800);clrscr();fout.open("mt.txt",ios::in);while(fout.read((char*)&a,sizeof(a))){a.result();}fout.close();for(i=0;i<80;i++)cout<<"=";cout<<"nn"<<endl;i=0;cout<<"Press Any Key To Continue"<<endl;getch();cout<<"nnRedirecting To ADMINS MENU "<<endl; 29
  30. 30. p1=1;a.admn();}else if(c1==m||c1==M){a.modify();}else if(c1==E||c1==e){ex:goto g;}else if(c1==b||c1==B){cout<<"nBooking List "<<endl;u.showbooked();a.admn();}else{cout<<"Wrong Choice nEnter Again"<<endl;p1=1;admn();delay(200);g:cout<<"Returning ....."<<char(24)<<endl;delay(1800);clrscr();}}}void admin::modify(){c1=y;while(c1==y||c1==Y){clrscr();delay(400);cout<<"t tttMODIFYING MENU"<<endl<<endl;delay(400);cout<<"tttt";cout<<" ADD movies "<<endl;cout<<"tttt";cout<<" " A ""<<endl;delay(400);cout<<endl;cout<<"tttttt"D" DELETE movies " <<endl;cout<<endl;delay(400);cout<<endl;cout<<"tttt";cout<<" " M " "<<endl;cout<<"tttt";cout<<" EDIT movies "<<endl;delay(400);gotoxy(12,6);cout<<"ADMINS menu "E""<<endl;gotoxy(38,6); 30
  31. 31. c2=getche();gotoxy(30,15);if(c2==a||c2==A){add();}else if(c2==m||c2==M){edit();}else if(c2==d||c2==D){del();}else if(c2==e||c2==E){goto mex;}else{cout<<"Wrong Choice"<<endl;}cout<<"nWant to continue modify"<<endl;c1=getche();}if(c1==n||c1==N){mex:p1=1;admn();}}void admin::settings(){i=0;int bk,tb;y:cout<<"Customize The Background Colour and Text Colour "<<endl;cout<<"Press 1 for Main Menu (Welcome Screen ) settings"<<endl;cout<<"Press 2 for Admin Menu settings"<<endl;cout<<"Press 3 for User Menu settings "<<endl;cout<<"Press 4 to return to admins menu"<<endl;cin>>i;;if(i>4){cout<<"WRONG CHOICE "<<endl;cout<<"Enter Again"<<endl;goto y;}if(i==4){cout<<"Returning "<<char(24)<<endl;delay(400);i=0;p1=1;p=0;goto d; 31
  32. 32. }cout<<"tt╔════════════════════════╗ "<<endl;cout<<"tt║number:color ║ "<<endl;cout<<"tt║ ║ "<<endl;cout<<"tt║ 0 = Black ║ "<<endl;cout<<"tt║ 1 = Blue ║ "<<endl;cout<<"tt║ 2 = Green ║ "<<endl;cout<<"tt║ 3 = Cyan ║ "<<endl;cout<<"tt║ 4 = Red ║ "<<endl;cout<<"tt║ 5 = Purple ║ "<<endl;cout<<"tt║ 6 = Yellow ║ "<<endl;cout<<"tt║ 7 = White ║ "<<endl;cout<<"tt╚════════════════════════╝ "<<endl;cout<<"nEnter the colour Number for Background colour ";cin>>bk;if(bk>7)bk=bk-1;cout<<"nEnter The Colour Number for Text Colour ";cin>>tb;cout<<endl<<endl;tb=tb+8;switch(i){case 1:mi=bk;mj=tb;break;case 2:ai=bk;aj=tb;break;case 3:ui=bk;uj=tb;break;}cout<<" Applying Settings ";for(i=0;i<6;i++){delay(500);cout<<".";}cout<<"n Settings Have Been Applied"<<endl;delay(700);cout<<" Note: You Need To Exit As Admin"<<endl;getch();p1=1;i=3;d:a.admn();}void admin::add() //For Adding Movies into The List{cout<<"ADDING MOVIES "<<endl;fout.open("mt.txt",ios::out|ios::app);do{cout<<"nMovie Name "<<endl; 32
  33. 33. gets(mname);cout<<"Language "<<endl;gets(mlang);cout<<"Rating "<<endl;cin>>mstars;cout<<"Description "<<endl;gets(mdes);cout<<"Actors "<<endl;gets(mactors);cout<<"Director "<<endl;gets(mdirector);cout<<"CBFC rating "<<endl;gets(mcbfc);cout<<"Timings"<<endl;gets(mtiming);cout<<"Price "<<endl;cin>>mprice;cout<<"Seats "<<endl;cin>>mseats;fout.write((char*)&a,sizeof(a));cout<<"nDetails Entered Successfully"<<endl;cout<<"nWant to add more movies(y/n)"<<endl;c2=getche();}while(c2==y||c2==Y);fout.close();}void admin::edit() //For Editing The Added Movies{p=0;r=0;float pos;fin.open("mt.txt",ios::in);fin.seekg(0);i=0;cout<<"Movies In IMAX :"<<endl;while(fin.read((char*)&a,sizeof(a))){delay(200);i++;cout<<i<<" ";cout<<char(14);cout<<" "<<mname<<endl;}fin.close();r=0;fin.open("mt.txt",ios::in|ios::out);char name[20];int nrating,nos;float nprice;char nname[20],ntim[20],ndes[10];cout<<"n"<<endl;cout<<"Editing "<<endl;cout<<"Enter The Movie Number To be Edited(0 to CancelEditting)"<<endl;cin>>r; 33
  34. 34. if(r==0)goto k;i=0;fin.seekp(0);while(fin){i++;pos=fin.tellg();fin.read((char*)&a,sizeof(a));if(i==r){cout<<"Movie Foundn Details";for(int h=0;h<6;h++){delay(90);cout<<".";}clrscr();result();cout<<"Now Edit"<<endl;cout<<"nnPress ! in any field to retain the old detail"<<endl;cout<<"Enter new Name: ";gets(nname);cout<<"Enter new Description: ";gets(ndes);cout<<"Enter new Timmings: ";gets(ntim);cout<<"Enter new Price: ";cin>>nprice;cout<<"Enter new rating(press 0 to retain old one): ";cin>>nrating;cout<<"No oF Seats";cin>>nos;if(strcmp(nname,"!")!=0)strcpy(mname,nname);if(strcmp(ndes,"!")!=0)strcpy(mdes,ndes);if(mprice!=nprice)mprice=nprice;if(nrating!=0)mstars=nrating;if(strcmp(ntim,"!")!=0)strcpy(mtiming,ntim);if(nos!=0)mseats=nos;fin.seekg(pos);fin.write((char*)&a,sizeof(a));fin.close();p=1;break;}}if(p==0){cout<<"Wrong Movie Number"<<endl;cout<<"Redirecting to modify menu"<<endl; 34
  35. 35. delay(300);modify();}fout.open("mt.txt",ios::in);cout<<"Now The Movies are.. :n"<<endl;delay(500);fout.seekg(0);clrscr();while(fout.read((char*)&a,sizeof(a))){result();}fout.close();for(i=0;i<80;i++)cout<<"=";cout<<"nn"<<endl;k:i=0;}void admin::result() //To Show Details Of A Movie{gotoxy(30,20);for(i=0;a.mname[i]!=0;i++){delay(30);cout<<a.mname[i];}cout<<" ";delay(200);gotoxy(31,21);cout<<a.mdes<<" ";gotoxy(27,25);delay(600);cout<<"DIRECTED by "<<a.mdirector<<" ";gotoxy(27,16);delay(500);cout<<"STARRING "<<a.mactors<<" ";gotoxy(4,19);delay(300);cout<<" LANGUAGE -"<<a.mlang<<" ";gotoxy(4,21);delay(300);cout<<" rating by CBFC-"<<a.mcbfc<<" ";gotoxy(4,23);delay(300);cout<<" ticket PRICE -"<<a.mprice<<" ";gotoxy(54,19 );delay(300);cout<<a.mseats<<"("<<a.tick<<")" <<"- SEATS remaining"<<endl;gotoxy(54,21);delay(300);cout<<a.mstars<<" - STARS out of 5"<<endl;gotoxy(54,23);delay(300);cout<<a.mtiming<<"- TIMMING"<<endl;i=0;getch(); 35
  36. 36. gotoxy(1,30);}void admin::del() //To Delete A Movie From List{p=0;i=0;r=0;fout.open("mt.txt",ios::in);fout.seekg(0);i=0;cout<<"Movies In IMAX :"<<endl;while(fout.read((char*)&a,sizeof(a))){delay(200);i++;cout<<i<<" ";cout<<char(16);cout<<" "<<mname<<endl;}fout.close();r=0;char dname[30];fin.open("mt.txt",ios::in);fout.open("temp.txt",ios::out);cout<<"Enter The Movie Number to be deleted "<<endl;cin>>r;i=0;while(fin.read((char*)&a,sizeof(a))){i++;if(i==r){cout<<"Movie Detailsn"<<endl;delay(300);clrscr();result();p=1;cout<<"Are You Sure You Want To DELETE This Movie "<<endl;cin>>c1;if(c1==n||c1==N)fout.write((char*)&a,sizeof(a));}elsefout.write((char*)&a,sizeof(a));}if(p==0){cout<<"Wrong Movie Number"<<endl;delay(500);cout<<"Returning "<<char(24);delay(1800);modify();}if(c1==y||c1==Y)cout<<"Movie Successfully Deleted"<<endl;fin.close();fout.close(); 36
  37. 37. remove("mt.txt");rename("temp.txt","mt.txt");fin.open("mt.txt",ios::in);cout<<"Now The Movies are :"<<endl;delay(900);clrscr();while(fin.read((char*)&a,sizeof(a))){a.result();}fin.close();cout<<"Press Any Key "<<endl;getch();}void admin::tcrun() //To Run Ticket Counter/InitialiseTickets{i=0;cout<<"nProcessing Movies List .";for(i=0;i<6;i++){delay(300);cout<<".";}cout<<endl<<endl;fout.open("mt.txt",ios::in);fout.seekg(0);i=0;while(fout.read((char*)&a,sizeof(a))){delay(300);i++;cout<<i<<" ";cout<<char(14);cout<<" "<<mname<<" _ "<<mseats<<endl;}fout.close();r=0;cout<<"nEnter the movie number to be initialised (0 toreturn)"<<endl;cin>>r;if(r==0)goto ex;fout.open("mt.txt",ios::in|ios::out);fout.seekg(0);i=0;int nseats;fout.seekg(0);while(!fout.eof()){i++;pos=fout.tellg();fout.read((char*)&a,sizeof(a));if(i==r){cout<<"nprocessing "<<mname<<endl;delay(400); 37
  38. 38. cout<<"Enter The No of seats for the movie"<<endl;cin>>nseats;delay(300);cout<<"Initialising tickets with 0"<<endl;mseats=nseats;tick=0;fout.seekg(pos);fout.write((char*)&a,sizeof(a));p=1;break;}}fout.close();if(p==0)cout<<"Movie Not Found"<<endl;cout<<"redirecting"<<endl;delay(400);ex:cout<<"nReturning To Main Menu"<<char(24)<<endl;delay(1800);p1=1;admn();}void admin::seatmanage(int s) //Function to Manage seats of amovie{ //after booking ,cancelling andmodifying....file.open("mt.txt",ios::in|ios::out);while(!file.eof()){pos=file.tellg();file.read((char*)&a,sizeof(a));if(strcmp(name,a.mname)==0){a.tick=a.tick+s;a.mseats=a.mseats-s;file.seekg(pos);file.write((char*)&a,sizeof(a));break;}}file.close();}void admin::amtcal(int c3){file.open("mt.txt",ios::in);while(file.read((char*)&a,sizeof(a))){if(strcmp(name,a.mname)==0){cout<<"Amount Payable :";delay(300);cout<<c3;delay(400);cout<<"x";delay(500);cout<<mprice; 38
  39. 39. delay(500);cout<<" = Rs.";delay(900);float q;q=mprice*(c3);cout<<q<<endl;break;}}file.close();} //End Of Functions Definition of class adminvoid user::umenu() //Funtion For User Modules Main Menu AndWelcome Screen{textcolor(uj);textbackground(ui);clrscr();if(p1==1)z:goto u;clrscr();cout<<"tttt DEAR USER"<<endl;u:char temp[40]={"W E L C O M E T O "I M A X" "};gotoxy(60,3);int x=70,y;for(i=0;i<45;i++){x--;delay(70);gotoxy(x,3);cout<<temp;cout<<" " ;}cout<<endl;cout<<"ntttt USERS MENU"<<endl<<endl;y=6,x=60;char book[]={"BOOK MOVIES"};char modi[]={"MODIFY BOOKING"};char canc[]={"CANCEL BOOKING"};char exit[]={"EXIT AS USER"};for(i=0;i<18;i++){if(i%2==0){y++;gotoxy(36,y);delay(70);cout<<book;gotoxy(36,y-1);cout<<" ";delay(70);gotoxy(36,40-y);cout<<exit;gotoxy(36,41-y); 39
  40. 40. cout<<" ";}else{x-- ;gotoxy(70-x,20);delay(70);cout<<modi;gotoxy(69-x,20);cout<<" ";delay(70);gotoxy(x,20);cout<<canc;cout<<" ";}}delay(200);gotoxy(40,23);cout<<""E"";delay(200);gotoxy(x-4,20);cout<<""C"";delay(200);gotoxy(40,y+2);cout<<""B"";delay(200);gotoxy(x-17,20);cout<<""M"";time_t t;t = time(NULL);gotoxy(2,8);cout<<"DATE-";gotoxy(8,8);cout<<ctime(&(t));gotoxy(18,8);cout<<"";gotoxy(55,8);cout<<ctime(&(t));gotoxy(55,8);cout<<" TIME- ";gotoxy(71,8);cout<<" ";gotoxy(41,20);c1=getche();gotoxy(39,28);if(c1==e||c1==E){goto f;}else if(c1==b||c1==B){p=0;cout<<"nBooking "<<endl;a:cout<<"Movies Now Playing in IMAX With Seat Numbers in ( )"<<endl;fin.open("mt.txt",ios::in);fin.seekg(0);i=0;cout<<endl;while(fin.read((char *)&a,sizeof(a))){delay(500);i++;cout<<i;cout<<" "<<char(14);cout<<" "<<a.mname<<" (";a.showseats();cout<<" )"<<endl;}fin.close();r=0;cout<<"nEnter The Number to Book (0 to exit)"<<endl;cin>>r; 40
  41. 41. if(r==0){cout<<"Returning.."<<char(24)<<endl;delay(1800);clrscr();goto z;}i=0;fin.open("mt.txt",ios::in);while(fin.read((char*)&a,sizeof(a))){i++;if(i==r){pos=fin.tellg();strcpy(u.mov,a.mname);ubooking();p=1;break;}}if(p==0){cout<<"Wrong Movie Number ... Choose Once Again"<<endl;fin.close();goto a;}}else if(c1==c||c1==C){u.ucancel();}else if(c1==M||c1==m){u.uedit();}else{cout<<"Wrong Choice"<<endl;cout<<"Enter Again "<<endl;umenu();}f:cout<<endl;}void user::ubooking(){cout<<"Movie Details :"<<endl;delay(500);clrscr();fin.seekg(pos);a.result();strcpy(name,a.mname);fin.close();gotoxy(40,40);cout<<"nMOVIE BOOKING "<<endl; 41
  42. 42. cout<<"Enter Your name "<<endl;gets(uname);cout<<"Enter your age "<<endl;cin>>uage;cout<<"Enter the no. of tickets to be booked "<<endl;cin>>uno;cout<<"Enter your phone number or email id"<<endl;gets(uphone);cout<<"Want To confirm booking for ";puts(name);c2=getche();if(c2==y){i=0;fout.open("mb.txt",ios::out|ios::app);cout<<"nYour Ticket number(s) are:"<<endl;tcallote();cout<<"Your Main Ticket number is: "<<u.utc<<endl;a.seatmanage(u.uno);fout.write((char*)&u,sizeof(u));a.amtcal(u.uno);delay(600);cout<<"nnT H A N K Y O U F O R B O O K I N G"<<char(1)<<char(2)<<endl;cout<<"Enjoy The Movie"<<endl;delay(80);cout<<endl<<endl;textcolor(ui+2);cputs("* NOTE :Use your Main Ticket Number Given Above");cout<<endl;cputs(" For Cancelling/Changing your Booking *");cout<<endl;fout.close();cout<<"Press Enter To Continue"<<endl;ch=getch();if(ch==r){cout<<"Redirecting to user menu"<<endl;cout<<char(24)<<endl;delay(1800);}umenu();}if(c2==n){p1=1;umenu();}}void user::tcallote() //Allocating Ticket Number After Booking aMovie{c2=n;int cnt=u.uno;fstream f1;int tics;f1.open("mt.txt",ios::app|ios::in);while(f1.read((char*)&a,sizeof(a))){ 42
  43. 43. if(strcmp(a.mname,name)==0){tics=a.tick;while(cnt>0){tics++;cnt--;cout<<tics<<endl;delay(300);}break;}}f1.close();u.utc=tics;}void user::ucancel() // For Cancelling The Movie Booked{cout<<"Enter The Movie U booked for"<<endl;fstream f1;f1.open("mb.txt",ios::in);i=0;f1.seekg(0);while(f1.read((char *)&u,sizeof(u))){i++;cout<<i<<" "<<char(13)<<" "<<mov<<endl;}r=0;f1.close();f1.open("mb.txt",ios::in);f1.seekg(0);cin>>r;i=0;while(f1.read((char *)&u,sizeof(u))){i++;if(i==r){strcpy(name,mov);cout<<"nMovie selected :"<<name<<endl;}}f1.close();cout<<"Canceling...."<<endl;cout<<"Enter Your Main Ticket Number "<<endl;cin>>r;fin.open("mb.txt",ios::in);fout.open("temp.txt",ios::out);while(fin.read((char*)&u,sizeof(u))){if((r==utc)&&strcmp(name,u.mov)==0){p=1;cout<<"FOUND"<<endl;cout<<"Name :";puts(uname);cout<<"Ticket No:"<<utc<<endl; 43
  44. 44. cout<<"Movie :"<<u.mov<<endl;strcpy(name,u.mov);cout<<"CANCEL BOOKING????"<<endl;c2=getche();if(c2==n||c2==N)fout.write((char*)&u,sizeof(u));}else{fout.write((char*)&u,sizeof(u));}}if(c2==y||c2==Y){strcpy(name,mov);cout<<"Your Ticket Is Successfully Cancelled"<<endl;a.seatmanage((-u.uno));}if(p==1&&c2!=y)cout<<"Your Ticket Is not Cancelled"<<endl;if(p!=1)cout<<"Not Found"<<endl;fin.close();fout.close();remove("mb.txt");rename("temp.txt","mb.txt");cout<<"Press Any Key"<<endl;getch();canex:cout<<"Redirecting to User Menu"<<char(24)<<endl;delay(1800);umenu();}void user::uedit() //For Changing The Details Of No. ofTickets,Contact Details{cout<<"Enter The Movie U booked for"<<endl;fstream f1;f1.open("mb.txt",ios::in);i=0;f1.seekg(0);while(f1.read((char *)&u,sizeof(u))){i++;cout<<i<<" "<<char(13)<<" "<<mov<<endl;}cin>>r;f1.close();i=0;f1.open("mb.txt",ios::in);f1.seekg(0);while(f1.read((char *)&u,sizeof(u))){i++;if(i==r){strcpy(name,u.mov); 44
  45. 45. cout<<"Movie Selected :"<<name;}}f1.close();float pos;int t;p=0;cout<<"nModify Your Booking "<<endl;fout.open("mb.txt",ios::in|ios::out);cout<<"Enter Your Ticket Number :"<<endl;cin>>t;int n;char cnt[30];fout.seekg(0);while(fout){pos=fout.tellg();fout.read((char*)&u,sizeof(u));if(t==u.utc&&strcmp(name,u.mov)==0){cout<<"OLD DETAILS "<<endl;i=uno;cout<<"Name :";puts(uname);cout<<"Movie :";puts(a.mname);cout<<"Age :"<<uage<<endl;cout<<"No. of Tickets Booked :"<<i<<endl;cout<<"Contact info :";puts(uphone);cout<<"nntEnter New Details"<<endl;cout<<"Enter Your Name "<<endl;gets(aname);cout<<"Enter the no. of tickects to be booked "<<endl;cin>>n;cout<<"Enter the contact details "<<endl;gets(cnt);if(strcmp(aname,"!")!=0)strcpy(uname,aname);if(strcmp(cnt,"!")!=0)strcpy(uphone,cnt);if(n!=0)uno=n;fout.seekg(pos);fout.write((char*)&u,sizeof(u));fout.close();p=1;break;}}if(p==0)cout<<"Not Found "<<endl;else{strcpy(name,u.mov);if(i>n) 45
  46. 46. a.seatmanage((n-i));if(n>i)a.seatmanage((i-n));delay(300);cout<<"Details Saved"<<endl;}cout<<"Press Any Key"<<endl;getch();cout<<"Redirecting to User Menu "<<char(24)<<endl;delay(1800);umenu();}void user::showbooked() //Function Used by Admin To See Booked List{cout<<" B O O K I N G L I S T "<<endl;fin.open("mb.txt",ios::in);while(fin.read((char*)&u,sizeof(u))){cout<<endl;for(i=0;i<70;i++)cout<<char(4);cout<<"nMovie Booked:"<<mov;cout<<"nName: ";puts(u.uname);cout<<"Ticket no:"<<u.utc<<endl;cout<<"Age :"<<u.uage<<endl;cout<<"No. Of Tickets: "<<u.uno<<endl;cout<<"Contact Details: "<<u.uphone<<endl;for(r=0;r<70;r++)cout<<char(4);getch();}cout<<endl<<endl;for(i=0;i<80;i++)cout<<char(39);cout<<"End Of Booked List"<<endl;fin.close();cout<<"Press Any Key To Continue"<<endl;getch();cout<<"Returning to Admins Menu"<<char(24)<<endl;delay(1000);p1=1;a.admn();} //END OF PROGRAM 46
  47. 47.  OUTPUTWelcome screens 47
  48. 48. 48
  49. 49. if choice = ‘a’(admin module) 49
  50. 50. if choice=’m’(modify menu) if choice=’a’(add movies)if choice=’d’(delete movies) 50
  51. 51. Back to Admins menu & choice==’a’(movies running)back to admin’s menu &choice=’s’(settings) 51
  52. 52. Back to welcome screenuser’s menu 52
  53. 53. if choice=’b’(book movies) 53
  54. 54. if choice==’c’(cancelling booking)if choice=’e’(exit as user) 54
  55. 55. Exit screen 55
  56. 56.  Bibliography www.cplusplus.com Help menu on turbo c++ Computer science with c++ (12th class text) 56
  57. 57. Thank you 57
  58. 58. 58

×