home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Intermedia 1998 January
/
inter1_98.iso
/
www
/
rozi
/
DIRPOP.PAS
< prev
next >
Wrap
Pascal/Delphi Source File
|
1997-12-15
|
1KB
|
65 lines
uses crt,dos;
var p:file of byte;
d:byte;
l:integer;
ver:word;
const tab1:array[1..10] of byte=($e8,$0b,$03,$a1,$1d,$a3,$0b,$c0,$74,$17);
tab2:array[1..10] of byte=($e8,$da,$02,$a1,$a7,$8d,$0b,$c0,$74,$17);
begin
writeln;
writeln('Errata do DIR');
write('<c>1997 by ');
textcolor(lightcyan);
writeln('Tytus Software');
textcolor(lightgray);
writeln('http://free.polbox.pl/t/tomekr');
writeln;
assign(p,'command.com');
setfattr(p,archive);
{I-}
reset(p);
{I+}
if ioresult<>0 then
begin
textcolor(red);
writeln('Nie moge otworzyc COMMAND.COM');
textcolor(lightgray);
halt;
end;
ver:=dosversion;
if (lo(ver)<6) and (hi(ver)<20) then
begin
writeln('DOS ',lo(ver),'.',hi(ver));
for l:=1 to 4340 do
begin
read(p,d);
end;
for l:=1 to 10 do
begin
write(p,tab2[l]);
end;
end;
if (lo(ver)>=6) and (hi(ver)>=20) then
begin
writeln('DOS ',lo(ver),'.',hi(ver));
for l:=1 to 14275 do
begin
read(p,d);
end;
for l:=1 to 10 do
begin
write(p,tab1[l]);
end;
end;
close(p);
assign(p,'command.com');
setfattr(p,readonly);
writeln;
writeln('O.K.');
end.