Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!csd4.milw.wisc.edu!lll-winken!ubvax!ardent!peck!rap From: rap@peck.ardent.com (Rob Peck) Newsgroups: comp.sys.amiga.tech Subject: Re: What is my name? Message-ID: <7330@ardent.UUCP> Date: 17 Jul 89 20:28:39 GMT References: <26385@agate.BERKELEY.EDU> Sender: news@ardent.UUCP Reply-To: rap@peck.ardent.com (Rob Peck) Organization: Ardent Computer Corp., Sunnyvale, CA Lines: 13 In article <26385@agate.BERKELEY.EDU> mwm@mica.berkeley.edu (Mike (I'll think of something yet) Meyer) writes: >Before I sit down & write it myself, does anyone have a piece of code >that will give me a full name for the binary it's running in? Not just >argv[0], but the name path & file name (not file, but c:file, or >sys:system/file, or whatever). Listing 2.9 in the Programmer's Guide To The Amiga gives you the path to where the binary is located. You can use argv[0] for the binary's name. The program is called mybranch.c Rob Peck