filenseq.icn: Procedure to get highest numbered filename in a sequence

link filenseq
May 2, 2001; David A. Gamey
Requires: MS-DOS or another congenial operating system
This file is in the public domain.

This procedure is useful when you need to create the next file
in a series of files (such as successive log files).

Usage:

fn := nextseqfilename( ".", "$", "log")

returns the (non-existent) filename next in the sequence .\$*.log
(where the * represents 1, 2, 3, ...) or fails

Source code | Program Library Page | Icon Home Page