Recent

Author Topic: What else/newer for Uses CRT?!  (Read 151 times)

coradi

  • Jr. Member
  • **
  • Posts: 90
What else/newer for Uses CRT?!
« on: November 07, 2019, 09:42:53 pm »
If I try this...it's all fine...but I need a delay...also I uses CRT..then the ansi table is wrong:-(
And ClrScr ist missing then..too

Code: Pascal  [Select]
  1. program symbolbild;
  2. // Uses crt;
  3.  
  4. VAR icon : array[1..7,1..7] of char;
  5.  
  6. Procedure Zahl(num:byte);
  7. //var number : byte;
  8. begin
  9.   case num of
  10.  
  11. 7:Begin
  12. {7}
  13. {1}  icon[1][1]:=chr(178); icon[1][2]:=chr(178); icon[1][3]:=chr(178); icon[1][4]:=chr(178); icon[1][5]:=chr(178);icon[1][6]:=chr(178);icon[1][7]:=chr(178);
  14. {2}  icon[2][1]:=chr(255); icon[2][2]:=chr(255); icon[2][3]:=chr(255); icon[2][4]:=chr(255); icon[2][5]:=chr(255);icon[2][6]:=chr(255);icon[2][7]:=chr(178);
  15. {3}  icon[3][1]:=chr(255); icon[3][2]:=chr(255); icon[3][3]:=chr(255); icon[3][4]:=chr(255); icon[3][5]:=chr(255);icon[3][6]:=chr(255);icon[3][7]:=chr(178);
  16. {4}  icon[4][1]:=chr(255); icon[4][2]:=chr(255); icon[4][3]:=chr(255); icon[4][4]:=chr(255); icon[4][5]:=chr(255);icon[4][6]:=chr(255);icon[4][7]:=chr(178);
  17. {5}  icon[5][1]:=chr(255); icon[5][2]:=chr(255); icon[5][3]:=chr(255); icon[5][4]:=chr(255); icon[5][5]:=chr(255);icon[5][6]:=chr(255);icon[5][7]:=chr(178);
  18. {6}  icon[6][1]:=chr(255); icon[6][2]:=chr(255); icon[6][3]:=chr(255); icon[6][4]:=chr(255); icon[6][5]:=chr(255);icon[6][6]:=chr(255);icon[6][7]:=chr(178);
  19. {7}  icon[7][1]:=chr(255); icon[7][2]:=chr(255); icon[7][3]:=chr(255); icon[7][4]:=chr(255); icon[7][5]:=chr(255);icon[7][6]:=chr(255);icon[7][7]:=chr(178);
  20.   end;
  21. 8:Begin
  22. {8}
  23. {1}  icon[1][1]:=chr(178); icon[1][2]:=chr(178); icon[1][3]:=chr(178); icon[1][4]:=chr(178); icon[1][5]:=chr(178);icon[1][6]:=chr(178);icon[1][7]:=chr(178);
  24. {2}  icon[2][1]:=chr(178); icon[2][2]:=chr(255); icon[2][3]:=chr(255); icon[2][4]:=chr(255); icon[2][5]:=chr(255);icon[2][6]:=chr(255);icon[2][7]:=chr(178);
  25. {3}  icon[3][1]:=chr(178); icon[3][2]:=chr(255); icon[3][3]:=chr(255); icon[3][4]:=chr(255); icon[3][5]:=chr(255);icon[3][6]:=chr(255);icon[3][7]:=chr(178);
  26. {4}  icon[4][1]:=chr(178); icon[4][2]:=chr(178); icon[4][3]:=chr(178); icon[4][4]:=chr(178); icon[4][5]:=chr(178);icon[4][6]:=chr(178);icon[4][7]:=chr(178);
  27. {5}  icon[5][1]:=chr(178); icon[5][2]:=chr(255); icon[5][3]:=chr(255); icon[5][4]:=chr(255); icon[5][5]:=chr(255);icon[5][6]:=chr(255);icon[5][7]:=chr(178);
  28. {6}  icon[6][1]:=chr(178); icon[6][2]:=chr(255); icon[6][3]:=chr(255); icon[6][4]:=chr(255); icon[6][5]:=chr(255);icon[6][6]:=chr(255);icon[6][7]:=chr(178);
  29. {7}  icon[7][1]:=chr(178); icon[7][2]:=chr(178); icon[7][3]:=chr(178); icon[7][4]:=chr(178); icon[7][5]:=chr(178);icon[7][6]:=chr(178);icon[7][7]:=chr(178);
  30.  end;
  31. 9:Begin
  32. {9}
  33. {1}  icon[1][1]:=chr(178); icon[1][2]:=chr(178); icon[1][3]:=chr(178); icon[1][4]:=chr(178); icon[1][5]:=chr(178);icon[1][6]:=chr(178);icon[1][7]:=chr(178);
  34. {2}  icon[2][1]:=chr(178); icon[2][2]:=chr(255); icon[2][3]:=chr(255); icon[2][4]:=chr(255); icon[2][5]:=chr(255);icon[2][6]:=chr(255);icon[2][7]:=chr(178);
  35. {3}  icon[3][1]:=chr(178); icon[3][2]:=chr(255); icon[3][3]:=chr(255); icon[3][4]:=chr(255); icon[3][5]:=chr(255);icon[3][6]:=chr(255);icon[3][7]:=chr(178);
  36. {4}  icon[4][1]:=chr(178); icon[4][2]:=chr(178); icon[4][3]:=chr(178); icon[4][4]:=chr(178); icon[4][5]:=chr(178);icon[4][6]:=chr(178);icon[4][7]:=chr(178);
  37. {5}  icon[5][1]:=chr(255); icon[5][2]:=chr(255); icon[5][3]:=chr(255); icon[5][4]:=chr(255); icon[5][5]:=chr(255);icon[5][6]:=chr(255);icon[5][7]:=chr(178);
  38. {6}  icon[6][1]:=chr(255); icon[6][2]:=chr(255); icon[6][3]:=chr(255); icon[6][4]:=chr(255); icon[6][5]:=chr(255);icon[6][6]:=chr(255);icon[6][7]:=chr(178);
  39. {7}  icon[7][1]:=chr(178); icon[7][2]:=chr(178); icon[7][3]:=chr(178); icon[7][4]:=chr(178); icon[7][5]:=chr(178);icon[7][6]:=chr(178);icon[7][7]:=chr(178);
  40.  end;
  41.   end; {endcase}
  42. end;
  43.  
  44. Procedure Ausgabe;
  45. VAR n, x,y : Byte;
  46. begin
  47.  x:=1;
  48.  y:=1;
  49.  
  50.   For n:=7 to 9 DO
  51.    Begin
  52.    Zahl(n);
  53.  
  54.   For y := 1 TO 7 DO
  55.     Begin
  56.       For x := 1 TO 7 DO
  57.         Begin
  58.           write(icon[y,x]);
  59.         end;
  60.       Writeln();
  61.     end;
  62.  
  63.   end;
  64. end;
  65.  
  66.  
  67. begin
  68.  Ausgabe;
  69.  readln();
  70. end.
  71.  
  72.  
« Last Edit: November 07, 2019, 09:48:24 pm by coradi »
Amstrad Schneider CPC 6128
Wind XP / 7 / 10

winni

  • Sr. Member
  • ****
  • Posts: 436
Re: What else/newer for Uses CRT?!
« Reply #1 on: November 07, 2019, 10:17:48 pm »
Hi!

ClrScr is in CRT.
Delay is in CRT.

Why do you need a ANSI table when your console is UTF8????
What are you trying to do???

You can save a lot of typing by using:

Code: Pascal  [Select]
  1.  icon[1,1]:=#178;

Don't know who is bying used brackets .....


Winni

coradi

  • Jr. Member
  • **
  • Posts: 90
Re: What else/newer for Uses CRT?!
« Reply #2 on: November 07, 2019, 10:21:47 pm »
don't know  why, before #178 doesn't work?!
Now it works fine..

I show Digits from 7 to 9 for this I need ansi
Without uses crt...The Digit works fine..with CRT it's the wrong ansi table
Amstrad Schneider CPC 6128
Wind XP / 7 / 10