Category : BASIC Source Code
Archive   : ASICIDEA.ZIP
Filename : BARMENU.ASI

 
Output of file : BARMENU.ASI contained in archive : ASICIDEA.ZIP
Beginit:
screen 0
TLCORNER$=CHR$(201)
ACROSS$=CHR$(205)
TRCORNER$=CHR$(187)
DOWN$=CHR$(186)
BLCORNER$=CHR$(200)
BRCORNER$=CHR$(188)
CLS
ChoiceOne$=" ChoiceOne "
ChoiceTwo$=" ChoiceTwo "
ChoiceThree$=" ChoiceThree "
ChoiceFour$=" ChoiceFour "

WinOneOne$="Directory "
WinOneTwo$="Choice Two "
WinOneThree$="Choice Three "
WinOneFour$="Select File "

WinTwoOne$="Choice One "
WinTwoTwo$="Choice Two "
WinTwoThree$="Choice Three "
WinTwoFour$="Choice Four "

WinThreeOne$="View Pcx File "
WinThreeTwo$="Choice Two "
WinThreeThree$="Choice Three "
WinThreeFour$="Choice Four "

WinFourOne$="Choice One "
WinFourTwo$="Choice Two "
WinFourThree$="Dos Shell "
WinFourFour$="End Program "

EW$=Space$(15)
sp$=space$(80)
sp2$=space$(78)
Start:
MenuSel=1
CH$=chr$(27)
MP=2
updown=2
downup=3
Enter$=chr$(13)
color 1,7
gosub WindowOne:
color 0,7
BarMenustart:
color 7,3
locate 0,0
print sp$;
color 0,7
locate 0,2
print ChoiceOne$
locate 0,22
print ChoiceTwo$
locate 0,42
print ChoiceThree$
locate 0,62
print ChoiceFour$
locate 24,1
print sp2$;
locate 24,27
print"Type the key to end";
color 7,0
BarMenu:

color 7,13
locate 0,MP
gosub MenuColor:
locate updown,downup
gosub UpDownColor:
color 7,0
gosub PauseScreen:
gosub EraseWindow:

color 0,7
locate 0,MP
gosub MenuColor:
locate updown,downup
gosub MenuColor:
color 7,0
if an$="M" then
MenuSel=MenuSel+1
updown=2
endif
if MenuSel=5 then
MenuSel=1
endif
if an$="K" then
MenuSel=MenuSel-1
updown=2
endif
if MenuSel=0 then
MenuSel=4
endif
if an$="H" then
updown=updown-1
endif
if an$="P" then
updown=updown+1
endif
if updown<2 then
updown=5
endif
if updown>5 then
updown=2
endif

REM MENU POSITION
if MenuSel=1 then
MP=2
ENDIF
if MenuSel=2 then
MP=22
ENDIF
if MenuSel=3 then
MP=42
ENDIF
if MenuSel=4 then
MP=62
ENDIF

GOSUB EraseWindow:
color 1,7
if MenuSel=1 then
GOSUB WindowOne:
endif
if MenuSel=2 then
gosub WindowTwo:
endif
if MenuSel=3 then
gosub WindowThree:
endif
if MenuSel=4 then
gosub WindowFour:
endif
downup=x1+2
color 0,7
goto BarMenu:

REM Erase last Window
EraseWindow:
for ew=1 to 6
locate ew,0
print sp$
next ew
return

WindowOne:
x1=1
y1=2
x2=16
y2=6
x3=x2+2
x=1
y=1
GOSUB DoBorder:
locate 2,3
print WinOneOne$
locate 3,3
print WinOneTwo$
locate 4,3
print WinOneThree$
locate 5,3
print WinOneFour$
return

WindowTwo:
x1=21
y1=2
x2=36
y2=6
x3=x2+2
x=21
y=1
gosub DoBorder:
locate 2,23
print WinTwoOne$
locate 3,23
print WinTwoTwo$
locate 4,23
print WinTwoThree$
locate 5,23
print WinTwoFour$
return

WindowThree:
x1=41
y1=2
x2=56
y2=6
x3=x2+2
x=41
y=1
Gosub DoBorder:
locate 2,43
print WinThreeOne$
locate 3,43
print WinThreeTwo$
locate 4,43
print WinThreeThree$
locate 5,43
print WinThreeFour$
return

WindowFour:
x1=61
y1=2
x2=76
y2=6
x3=x2+2
x=61
y=1
Gosub DoBorder:
locate 2,63
print WinFourOne$
locate 3,63
print WinFourTwo$
locate 4,63
print WinFourThree$
locate 5,63
print WinFourFour$
return

PauseScreen:
an$=inkey$
IF an$="" then PauseScreen:
if an$=Enter$ then
if updown=2 then
if MenuSel=1 then
OnlyDir=1
Search$="*.*"
goto UserFileSelection:
endif
endif
endif

if an$=Enter$ then
if updown=5 then
if MenuSel=1 then
Search$="*.ASI"
goto UserFileSelection:
endif
endif
endif

if an$=Enter$ then
if updown=2 then
if MenuSel=3 then
Search$="*.pcx"
search=2
gosub UserFileSelection:
cls

YourFile$=" "+YourFile$
cls
call("showpcx.exe",YourFile$)
cls
an$=""
rem run"BARMENU.COM"
goto beginit:
endif
endif
endif

if an$=Enter$ then
if updown=4 then
if MenuSel=4 then
cls
locate 6,25
Print"Type Exit to Return to Program"
call ("c:\dos\command.com","")
cls
goto Start:
endif
endif
endif

if an$=Enter$ then
if updown=5 then
if MenuSel=4 then
End
endif
endif
endif

IF an$=CH$ then
CLS
END
ENDIF
return

REM Draw Window Box
DoBorder:
locate y,x
PRINT TLCORNER$;
FOR BORD=x1 TO x2
PRINT ACROSS$;
NEXT BORD
PRINT TRCORNER$
FOR BORD=y1 TO y2
LOCATE BORD,x1
PRINT DOWN$;
print" ";
x6=x3-1
locate BORD,x6
print" ";
LOCATE BORD,x3
PRINT DOWN$;
NEXT BORD
locate y2,x1
PRINT BLCORNER$;
FOR BORD=x1 TO x2
PRINT ACROSS$;
NEXT BORD
PRINT BRCORNER$;
RETURN
END

REM routine to change color of BarMenu Selection
MenuColor:
if MenuSel=1 then
print ChoiceOne$
endif
if MenuSel=2 then
print ChoiceTwo$
endif
if MenuSel=3 then
print ChoiceThree$
endif
if MenuSel=4 then
print ChoiceFour$
endif
return

UpDownColor:
if updown=2 then

if MenuSel=1 then
print WinOneOne$;
endif
endif

if updown=2 then
if MenuSel=2 then
print WinTwoOne$;
endif
endif

if updown=2 then
if MenuSel=3 then
print WinThreeOne$;
endif
endif

if updown=2 then
if MenuSel=4 then
print WinFourOne$;
endif
endif

if updown=3 then
if MenuSel=1 then
print WinOneTwo$;
endif
endif

if updown=3 then
if MenuSel=2 then
print WinTwoTwo$;
endif
endif

if updown=3 then
if MenuSel=3 then
print WinThreeTwo$;
endif
endif

if updown=3 then
if MenuSel=4 then
print WinFourTwo$;
endif
endif

if updown=4 then
if MenuSel=1 then
print WinOneThree$;
endif
endif

if updown=4 then
if MenuSel=2 then
print WinTwoThree$;
endif
endif

if updown=4 then
if MenuSel=3 then
print WinThreeThree$;
endif
endif

if updown=4 then
if MenuSel=4 then
print WinFourThree$;
endif
endif

if updown=5 then
if MenuSel=1 then
print WinOneFour$;
endif
endif

if updown=5 then
if MenuSel=2 then
print WinTwoFour$;
endif
endif

if updown=5 then
if MenuSel=3 then
print WinThreeFour$;
endif
endif

if updown=5 then
if MenuSel=4 then
print WinFourFour$;
endif
endif
return


REM Select File Routine for Asic Program
UserFileSelection:
FileNam$=""
MatchFile=0
YourFile$=""
count=1
col=1
row=3
GetDirectory:
cls
DirPath$=GetDir(0)
locate 0,20
print"Current Directory of "
locate 0,41
print DirPath$
rem Search$="*.ASI"
Attrib=0
FileNam$=find first(Search$,Attrib)
if error>0 then done:
locate row,col
count$=str$(count)
count$=ltrim$(count$)
print " ";
print count$;
print" ";
print FileNam$

Loop:FileNam$=find continue
if error>0 then done:
count=count+1
row=row+1
if count=21 then
col=20
row=3
endif
if count=41 then
col=40
row=3
endif
if count=61 then
col=60
row=3
endif
locate row,col
count$=str$(count)
count$=ltrim$(count$)
sizeof=len(count$)
if sizeof<2 then
print" ";
endif
print count$;
print" ";
print FileNam$
goto Loop:
Done:
if OnlyDir>0 then
OnlyDir=0
goto WaitonKey:
endif

locate 23,30
print"Input File Number ";
input Selection
rem Search$="*.ASI"
Attrib=0
FileNam$=find first(Search$,Attrib)
if error>0 then GotFile:
MatchFile=MatchFile+1
if MatchFile=Selection then
YourFile$=FileNam$
endif
Loop2:FileNam$=find continue
if error>0 then GotFile:
MatchFile=MatchFile+1
if MatchFile=Selection then
YourFile$=FileNam$
endif
goto Loop2:
GotFile:
locate 24,25
print "Your Selection was ";
print YourFile$;

if search>0 then
search=0
return
endif

WaitonKey:
an$=inkey$
if an$="" then WaitonKey:
cls
goto Start:
end


  3 Responses to “Category : BASIC Source Code
Archive   : ASICIDEA.ZIP
Filename : BARMENU.ASI

  1. Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!

  2. This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.

  3. But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/