home *** CD-ROM | disk | FTP | other *** search
/ Jason Aller Floppy Collection / 189.img / TCS120S.ZIP / VIEWANSI.PAS < prev    next >
Pascal/Delphi Source File  |  1989-03-20  |  2KB  |  60 lines

  1. {$R-,S-,I-,D-,F+,V-,B-,N-,L+,O+ }
  2. {$M 65500,0,0 }
  3.  
  4. unit viewansi;
  5.  
  6. interface
  7.  
  8. uses crt,dos,
  9.      gentypes,configrt,modem,statret,gensubs,subs1,windows,subs2,textret,
  10.      mailret,userret,flags,mainr1,ansiedit,lineedit,chatstuf,
  11.      mainr2,overret1;
  12.  
  13. procedure viewansiscreens;
  14.  
  15. implementation
  16.  
  17. procedure viewansiscreens;
  18. var bobway:integer;
  19.     p:lstr;
  20.     asciiiii:boolean;
  21. begin
  22.  if numwelcomes<1 then begin
  23.   writeln;
  24.   writeln (^S'There are no Ansi Screens currently available'^R);
  25.   writeln;
  26.   exit;
  27.  end else
  28.  repeat
  29.   asciiiii:=false;
  30.   p:='';
  31.   if ansi then write (direct,#27+'[2J') else write (direct,^L);
  32.   writeln (^P'-=[ '^S'Ansi Welcome Screens '^P']=-');
  33.   writeln;
  34.   writeln (^R'There are '^S,numwelcomes,^R' Ansi screens.'^M);
  35.   if exist (textfiledir+'Welcome.ASC') then asciiiii:=true;
  36.   if asciiiii then writeln ('There is '^S'1'^R' Ascii Screen.'^M);
  37.   p:='Enter Choice [#1-'+strr(numwelcomes)+']-';
  38.   if asciiiii then p:=p+'[A/Ascii]-';
  39.   p:=p+'[Q/Quit]:';
  40.   writestr (p);
  41.   bobway:=valu(input);
  42.   if upcase(input[1])='A' then begin
  43.    printfile (textfiledir+'WELCOME.ASC');
  44.    writestr ('Press [Return] to continue.*');
  45.   end;
  46.   if valu(input) in [1..numwelcomes] then begin
  47.    if ansi then begin
  48.     if bobway>numwelcomes then
  49.     writeln (^M'There are only '+strr(numwelcomes)+' screens!') else
  50.     printfile (textfiledir+'Welcome'+strr(bobway)+'.Ans');
  51.     movexy (1,urec.displaylen);
  52.     writestr ('Press [Return] to continue.*');
  53.    end;
  54.   end;
  55.  until upcase(input[1])='Q';
  56. end;
  57.  
  58. begin
  59. end.
  60.