Category : Science and Education
Archive   : WDBDISK5.ZIP
Filename : LPOINTS.PAS

 
Output of file : LPOINTS.PAS contained in archive : WDBDISK5.ZIP
PROGRAM LPOINTS(INPUT, OUTPUT); {list the points in a WDB file in ascii form}

TYPE POINT = RECORD
CODE : INTEGER;
LAT : INTEGER;
LON : INTEGER
END;

VAR I,
K : INTEGER;
NEWPOINT : POINT;
INFILE : FILE OF POINT;
INFILE_NAME : STRING(14);

BEGIN { main driver }
WRITELN('LPOINTS lists the contents of the selected WDB file as follows :');
WRITELN;
WRITELN('DETAIL-CODE LATITUDE LONGITUDE.');
WRITELN;
WRITELN('The header record for line segments and point records are marked');
WRITELN(' with a trailing *****.');
WRITELN;
WRITELN('Negative values are West and South coordinates.');
WRITELN('Coordinates are expressed in integer minutes.');
WRITELN;
WRITELN('Depress CTRL-C to terminate the program.');
WRITELN;

WRITE('Enter name of the WDB input file > ');
READLN(INFILE_NAME);
WRITELN;

ASSIGN(INFILE, INFILE_NAME);
RESET(INFILE);

I := 0;

WHILE NOT EOF(INFILE) DO
BEGIN
READ(INFILE, NEWPOINT);
I := I + 1;
WITH NEWPOINT DO
IF CODE > 5
THEN
BEGIN
I := I - 1;
WRITELN(CODE:5,' ',LAT:5,' ',LON:5,' *****' )
END
ELSE WRITELN(CODE:5,' ',LAT:5,' ',LON:5);
END;
WRITELN;
WRITELN(INFILE_NAME,'contains ',I,'points.');
WRITELN;

CLOSE(INFILE);

END. { MAIN DRIVER }



  3 Responses to “Category : Science and Education
Archive   : WDBDISK5.ZIP
Filename : LPOINTS.PAS

  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/