type
  String64 = string[64];

procedure Read_Int(Request:  String64; var N:  integer);

  var
    In_Str:  String64;
    Code:  integer;
    Bad:  boolean;

  begin             {RI}
    repeat
      TextColor(YELLOW);
      TextBackground(RED);
      GotoXY(5, WhereY);
      ClrEol;
      Write(Request, '  ');
      TextBackground(BLACK);
      TextColor(CYAN);
      Readln(In_Str);
      Val(In_Str, N, Code);
      Bad := (Code <> 0) or (In_Str[1] = '$');
      if Bad then
      begin
        TextBackground(LIGHTGRAY);
        TextColor(BLACK + BLINK);
        GotoXY(56, WhereY - 1);
        Write(' NON INTEGER ENTRY ');
        Delay(1500)
      end
    until not Bad;
    TextColor(YELLOW);
    TextBackground(BLACK)
  end;              {RI}