TIP: Click on subject to list as thread! ANSI
echo: os2prog
to: Richard Hulme
from: Ed Becker
date: 1995-04-22 11:46:06
subject: Unique Filenames

Hello Richard!

Replying to a message of Richard Hulme to All:

 RH> Hello there!

 RH> I have a feeling this has been asked/explained before, but anyway....

 RH> How can I create a file with a unique filename under OS/2?  I've
 RH> looked through the Control Programming reference (including a search
 RH> on 'unique') but I can't seem to find anything.

There is an ANSI-C/SAA command called tmpnam: 

#include 

char *tmpnam(char *string)

It gives a unique filename that does not already exist.  It's available
with Cset and I'm sure any other ANSI compiler.

Look in your C reference manual that came with your compiler... It's not in
Control Program.INF.

Ed Becker
1:3618/7{at}fidonet

--- FleetStreet 1.03 NR
* Origin: The Land Of Mordor/2 - (904) 532-0471 (1:3618/7)
SEEN-BY: 105/42 620/243 711/401 409 410 413 430 807 808 809 934 955 712/407
SEEN-BY: 712/515 628 704 713/888 800/1 7877/2809
@PATH: 3618/7 5 12 3615/50 396/1 270/101 105/103 42 712/515 711/808 809 934

SOURCE: echomail via fidonet.ozzmosis.com

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.