Path: csiph.com!eternal-september.org!feeder.eternal-september.org!nntp.eternal-september.org!.POSTED!not-for-mail From: Martin Newsgroups: comp.sys.acorn.programmer Subject: Re: Name of a program Date: Thu, 16 Apr 2026 18:17:48 +0100 Organization: None Lines: 17 Message-ID: <5cca87776fNews04@avisoft.f9.co.uk> References: <5cca837cdbbob@sick-of-spam.invalid> Injection-Date: Thu, 16 Apr 2026 17:17:55 +0000 (UTC) Injection-Info: dont-email.me; posting-host="583e7422536fefdabac1b4c86289d4a5"; logging-data="1956432"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19GR0Q+5RINMqIb51CFZ2Ba" User-Agent: Pluto/3.21a (RISC OS/5.31) NewsHound/v1.54 Cancel-Lock: sha1:hq6RTCjoRey4E6rM8M5ax4Pz5Cs= Xref: csiph.com comp.sys.acorn.programmer:6623 In article <5cca837cdbbob@sick-of-spam.invalid>, Bob Latham wrote: > How can I get the name of program I'm running from within the > program? I would have thought that a program would know what it is called?! So not sure what you are wanting. You can get the command used to start the program, if that is any help, by using SWI OS_GetEnv. The name of the program file run will be in that command, but the command will need parsing to get it. OS_Args could be used to help that, or do it 'manually' in the program. -- Martin Avison Note that unfortunately this email address will become invalid without notice if (when) any spam is received.