1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212
|
int i=0,k=0;
clrscr();
for(i=0;i<ctr;i++)
{
gotoxy(2,1);printf("Account Number");
gotoxy(2,2+i);cprintf("%s",rec[i].acct_num);
gotoxy(30,1);cprintf("Transaction Type");
if (strcmpi(rec[i].trans_type,"Withdrawal")==0)
{
gotoxy(30,2+i);
cprintf("%s",rec[i].trans_type);
k++;
}
}
}
void dep_det()
{
textcolor(WHITE);textbackground(BLACK);
int i=0,t=0,k=0;
clrscr();
for(i=0;i<ctr;i++)
{
gotoxy(2,1);printf("Account Number");
gotoxy(2,2+i);cprintf("%s",rec[i].acct_num);
gotoxy(30,1);cprintf("Transaction Type");
if (strcmpi(rec[i].trans_type,"Deposit")==0)
{
gotoxy(30,2+i);
cprintf("%s",rec[i].trans_type);
k++;
}
}
}
void deposit(int i)
{
float dep;
int t=0;
clrscr();
cout<<"Enter amount to be deposit: P";
cin>>dep;
info[i].in_bal+=dep;
printf("Current balance P%.2f",info[i].in_bal);
rec[t].trans_code=t+1;
strcpy(rec[t].acct_num,info[i].acct_num);
strcpy(rec[i].trans_type, "Deposit");
rec[t].amt=dep;
getch();
}
void inquire(int i)
{
//int i=0;
clrscr();
printf("Current Balance %.2f",info[i].in_bal);
getch();
}
void mainmenu()
{
char choice,ans;
textcolor(WHITE);
textbackground(BLUE);
clrscr();
textcolor(0);
textbackground(7);
gotoxy(1,1);cprintf(" BANCO DE PENINSULARES ");
gotoxy(1,25);cprintf("Teller in charge: %s",user);
gotoxy(24,7); cprintf("ÉÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍ»");
gotoxy(24,8); cprintf("º M A I N M E N U º");
gotoxy(24,9); cprintf("ÌÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍ͹");
gotoxy(24,10);cprintf("º [A] : ACCOUNT º");
gotoxy(24,11);cprintf("º [T] : TRANSACTION º");
gotoxy(24,12);cprintf("º [D] : DISPLAY REPORT º");
gotoxy(24,13);cprintf("º º");
gotoxy(24,14);cprintf("º [X] : EXIT º");
gotoxy(24,15);cprintf("ÌÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍ͹");
gotoxy(24,16);cprintf("º Enter your choice: º");
gotoxy(24,17);cprintf("ÈÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍͼ");
textcolor(RED);
gotoxy(45,16);
choice=getch();
switch(choice)
{
case 'A':
case 'a':
{
clrscr();
textcolor(WHITE);textbackground(BLUE);
gotoxy(1,1); cprintf("ÉÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍËÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍËÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍ»");
gotoxy(1,2); cprintf("º [N]ew Account º [V]iew Account º [E]dit Account º");
gotoxy(1,3); cprintf("ÌÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÊÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÊÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍ͹");
gotoxy(1,4); cprintf("º º");
gotoxy(1,5); cprintf("º º");
gotoxy(1,6); cprintf("º º");
gotoxy(1,7); cprintf("º º");
gotoxy(1,8); cprintf("º º");
gotoxy(1,9); cprintf("º º");
gotoxy(1,10);cprintf("º º");
gotoxy(1,11);cprintf("º º");
gotoxy(1,12);cprintf("º º");
gotoxy(1,13);cprintf("º º");
gotoxy(1,14);cprintf("º º");
gotoxy(1,15);cprintf("º º");
gotoxy(1,16);cprintf("º º");
gotoxy(1,17);cprintf("º º");
gotoxy(1,18);cprintf("º º");
gotoxy(1,19);cprintf("º º");
gotoxy(1,20);cprintf("º º");
gotoxy(1,21);cprintf("º º");
gotoxy(1,22);cprintf("º º");
gotoxy(1,23);cprintf("º º");
gotoxy(1,24);cprintf("ÈÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍͼ");
top:
choice=getch();
switch(choice)
{
case 'N':
case 'n':
new_acct();
mainmenu();
case 'V':
case 'v':
disp_acct();
getch();
mainmenu();
case 'E':
case 'e':
edit_acct();
getch();
mainmenu();
default:
textbackground(BLACK);
textcolor(RED+BLINK);
gotoxy(28,10);cprintf(" Invalid Input!!! ");
gotoxy(28,12);printf("PRESS ANY KEY TO CONTINUE!");
getch();
mainmenu();
}//break;
case 'T':
case 't':
transac();
mainmenu();
}
case 'D':
case 'd':
disp_rep();
mainmenu();
case 'X':
case 'x':
textcolor(RED+BLINK);
gotoxy(26,16);cprintf("Are you sure? [Y/N]: ");
ans=getch();
if (ans=='Y'||ans=='y')
exit(1);
else if (ans=='N'|| ans== 'n')
mainmenu();
else
{
textcolor(RED+BLINK);
gotoxy(26,16);cprintf(" Invalid Input!!! ");
getch();
mainmenu();
}
break;
default:
textcolor(RED+BLINK);
gotoxy(26,16);cprintf(" Invalid Input!!! ");
getch();
mainmenu();
break;
}
}
void welcome()
{
textcolor(WHITE);
textbackground(BLACK);
clrscr();
_setcursortype(_NOCURSOR);
textbackground(BLACK);
textcolor(BLUE);
// delay(1000);
gotoxy(15,6); cprintf("ÛÛÛÛÛÛÛÛÛÛÛ ÛÛÛÛÛÛÛÛÛÛ ÛÛÛÛÛÛÛÛÛÛ");
// delay(1000);
gotoxy(15,7); cprintf("ÛÛÛ ÛÛ ÛÛÛ ÛÛÛ ÛÛÛ ÛÛÛÛ");
//delay(1000);
gotoxy(15,8); cprintf("ÛÛÛ ÛÛÛ ÛÛÛ ÛÛÛÛ ÛÛÛ ÛÛÛÛ");
//delay(1000);
gotoxy(15,9); cprintf("ÛÛÛ ÛÛÛ ÛÛÛ ÛÛÛÛ ÛÛÛ ÛÛÛÛ");
//delay(1000);
gotoxy(15,10);cprintf("ÛÛÛ ÛÛÛÛ ÛÛÛ ÛÛÛÛ ÛÛÛ ÛÛÛÛ");
//delay(1000);
gotoxy(15,11);cprintf("ÛÛÛÛÛÛÛÛÛÛÛÛÛ ÛÛÛ ÛÛÛÛ ÛÛÛÛÛÛÛÛÛÛ");
//delay(1000);
gotoxy(15,12);cprintf("ÛÛÛ ÛÛÛÛ ÛÛÛ ÛÛÛÛ ÛÛÛ");
//delay(1000);
gotoxy(15,13);cprintf("ÛÛÛ ÛÛÛ ÛÛÛ ÛÛÛÛ ÛÛÛ");
//delay(1000);
gotoxy(15,14);cprintf("ÛÛÛ ÛÛÛ ÛÛÛ ÛÛÛÛ ÛÛÛ");
//delay(1000);
gotoxy(15,15);cprintf("ÛÛÛ ÛÛ ÛÛÛ ÛÛÛÛ ÛÛÛ");
// delay(1000);
gotoxy(15,16);cprintf("ÛÛÛÛÛÛÛÛÛÛÛ ÛÛÛÛÛÛÛÛÛÛ ÛÛÛ");
textcolor(WHITE);
textbackground(BLUE);
// delay(1000);
gotoxy(29,18);cprintf(" Banco De Peninsulares ");
//delay(1000);
gotoxy(29,19);cprintf(" MINI BANKING SYSTEM ");
delay(1000);
gotoxy(27,21);cprintf("Press any key to continue.....");
getch();
login();
}
|