Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
|
|
@ -0,0 +1,37 @@
|
|||
NOTES: procedure (text) options (main); /* 8 April 2014 */
|
||||
declare text character (100) varying;
|
||||
declare note_file file;
|
||||
|
||||
on undefinedfile(note_file) go to file_does_not_exist;
|
||||
open file (note_file) title ('/NOTES.TXT,recsize(100),type(text)');
|
||||
revert error;
|
||||
|
||||
if text = '' then
|
||||
do;
|
||||
on endfile (note_file) stop;
|
||||
|
||||
do forever;
|
||||
get file (note_file) edit (text) (L);
|
||||
put skip list (text);
|
||||
end;
|
||||
end;
|
||||
close file (note_file);
|
||||
open file (note_file) output title ('/NOTES.TXT,recsize(100),type(text),append(y)');
|
||||
|
||||
put file (note_file) skip list (DATETIME('DDMmmYYYY'), TIME());
|
||||
put file (note_file) skip list (text);
|
||||
put file (note_file) skip;
|
||||
|
||||
put skip list ('Appended ' || text || ' to file');
|
||||
|
||||
return;
|
||||
|
||||
file_does_not_exist:
|
||||
revert undefinedfile (note_file);
|
||||
close file (note_file);
|
||||
open file (note_file) output title ('/NOTES.TXT,recsize(100),type(text)');
|
||||
put file (note_file) skip list (DATETIME('DDMmmYYYY'), TIME());
|
||||
put file (note_file) skip list (text);
|
||||
put file (note_file) skip;
|
||||
put skip list ('The file, NOTES.TXT, has been created');
|
||||
end NOTES;
|
||||
Loading…
Add table
Add a link
Reference in a new issue