22 lines
708 B
Text
22 lines
708 B
Text
*Process source or(!);
|
|
/*********************************************************************
|
|
* 20.10.2013 Walter Pachl
|
|
* 'set dd:f=d:\_l\xxx.txt,recsize(300)'
|
|
* 'tex'
|
|
*********************************************************************/
|
|
tex: Proc Options(main);
|
|
Dcl fid Char(30) Var Init('D:\_l\tst.txt');
|
|
Dcl xxx Char(30) Var Init('D:\_l\nix.txt');
|
|
Dcl r Char(1000) Var;
|
|
Dcl f Record input;
|
|
On Undefinedfile(f) Goto label;
|
|
Open File(f) Title('/'!!fid);
|
|
Read file(f) Into(r);
|
|
Put Skip List('First line of file '!!fid!!': '!!r);
|
|
Close File(f);
|
|
Open File(f) Title('/'!!xxx);
|
|
Read file(f) Into(r);
|
|
Put Skip List(r);
|
|
Close File(f);
|
|
Label: Put Skip List('File '!!xxx!!' not found');
|
|
End;
|