Here is my
new program thus far and it
WORKS !
cls
set display mode 1920,1080,32
set text font "tiredofcourier":set text size 26
set text to bold:set text opaque
hide mouse
_start:
cls
dim FD$(10,500):dim Q$(10)
ink rgb(0,100,0),0:box 0,0,1920,64
ink rgb(0,0,0),0:box 0,16,1920,50
Q$(1)="Current Month":Q$(2)="Previous Month":Q$(3)="Search"
e=650:h=260:i=3:r=0
gosub _menu1
if r=1 then goto _CM
if r=2 then goto _PM
goto _search
_CM:
GD$=get date$():GD1$=left$(GD$,2):GD2$=right$(GD$,2):CM$=GD1$+"-"+GD2$+".dbf"
if file exist (CM$) = 0 then goto _CM02
open to read 1,CM$
for x = 1 to 501
for y = 1 to 9
read string 1,FD$(x,y)
if FD$(x,y)="end" then goto _CM01
next y
next x
_CM01:
close file 1
LN=(x-1)
goto _CM03
_CM02:
LN=24
gosub _titles
gosub _linenumbers
gosub _Bmenu
e=600:h=260:i=3
Q$(1)="New Month":Q$(2)="New Account":Q$(3)="Main Menu"
gosub _menu2
if r=1 then goto _NM
if r=2 then goto _NA
goto _start
_NA:
ink rgb(255,0,0),0:set cursor 400,500:print "new account";
goto _wk
_NM:
ink rgb(0,0,255),0:set cursor 400,500:print "new month";
goto _wk
_CM03:
_PM:
_search:
_wk:
wait key
_end:
end
rem ==========================================================================================================================================
function clearbuffer()
while inkey$() <> ""
r=0
endwhile
endfunction
_titles:
ink rgb(0,100,0),0:box 0,0,1920,64
ink rgb(0,0,0),0:box 0,16,1920,50
ink rgb(0,0,255),0:set cursor 10,19:print "LINE";
set cursor 130,19:print "DATE";
set cursor 245,19:print "TRANSACTION";
set cursor 420,19:print "LOCATION";
set cursor 840,19:print "DESCRIPTION";
set cursor 1285,19:print "AMOUNT";
set cursor 1436,19:print "BALANCE";
set cursor 1574,19:print "CLEARED";
set cursor 1734,19:print "BANK";
return
_Bmenu:
ink rgb(0,0,50),0:box 0,1030,1920,1080
ink rgb(0,0,0),0:box 0,1040,1920,1070
return
_linenumbers:
f=70
if LN > 24 then N=24 else N=LN
for x = 1 to N
if x < 10 then np=8 else np=0
ink rgb(150,150,150),0:set cursor (20+np),f:print str$(x);
ink rgb(30,30,30),0:box 0,(f+34),1920,(f+36)
f=(f+40)
next x
return
_menu1:
clearbuffer()
for x = 1 to i
ink rgb(110,150,240),0:set cursor e,19:print "( )";
ink rgb(150,0,200),0:set cursor (e+21),19:print str$(x);
ink rgb(150,150,150),0:set cursor (e+58),19:print Q$(x);
e=(e+h)
next x
_menu01:
if keystate(79) = 1 then r=1:goto _endm1
if keystate(80) = 1 then r=2:goto _endm1
if i = 2 then goto _menu01
if keystate(81) = 1 then r=3:goto _endm1
if i = 3 then goto _menu01
if keystate(75) = 1 then r=4:goto _endm1
if i = 4 then goto _menu01
if keystate(76) = 1 then r=5:goto _endm1
if i = 5 then goto _menu01
if keystate(77) = 1 then r=6:goto _endm1
goto _menu01
_endm1:
ink rgb(0,0,0),0:box 0,16,1920,50
return
_menu2:
clearbuffer()
for x = 1 to i
ink rgb(110,150,240),0:set cursor e,1040:print "( )";
ink rgb(150,0,200),0:set cursor (e+21),1040:print str$(x);
ink rgb(80,40,20),0:set cursor (e+58),1040:print Q$(x);
e=(e+h)
next x
_menu02:
if keystate(79) = 1 then r=1:goto _endm2
if keystate(80) = 1 then r=2:goto _endm2
if i = 2 then goto _menu02
if keystate(81) = 1 then r=3:goto _endm2
if i = 3 then goto _menu02
if keystate(75) = 1 then r=4:goto _endm2
if i = 4 then goto _menu02
if keystate(76) = 1 then r=5:goto _endm2
if i = 5 then goto _menu02
if keystate(77) = 1 then r=6:goto _endm2
_endm2:
ink rgb(0,0,0),0:box 0,1040,1920,1070
return
-majic-