Groups | Search | Server Info | Login | Register
Groups > comp.sys.acorn.programmer > #6632
| Path | csiph.com!eternal-september.org!feeder.eternal-september.org!nntp.eternal-september.org!.POSTED!not-for-mail |
|---|---|
| From | Martin <News04@avisoft.f9.co.uk> |
| Newsgroups | comp.sys.acorn.programmer |
| Subject | Re: Name of a program |
| Date | Fri, 17 Apr 2026 16:52:38 +0100 |
| Organization | None |
| Lines | 59 |
| Message-ID | <5ccb038169News04@avisoft.f9.co.uk> (permalink) |
| References | <5cca837cdbbob@sick-of-spam.invalid> <5cca87776fNews04@avisoft.f9.co.uk> <5cca8d05ebbob@sick-of-spam.invalid> <01ece1ca5c.harriet@bazleyfamily.co.uk> <F4l*XoiEA@news.chiark.greenend.org.uk> <5ccaee3398bob@sick-of-spam.invalid> |
| Injection-Date | Fri, 17 Apr 2026 15:53:49 +0000 (UTC) |
| Injection-Info | dont-email.me; posting-host="9841f27a00525ddb8f2f2ea4ae6cc908"; logging-data="2704759"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/HTBR92dp2iW7D7TAQADrF" |
| User-Agent | Pluto/3.21a (RISC OS/5.31) NewsHound/v1.54 |
| Cancel-Lock | sha1:t1JR8+iyEfBAx9sNq3gG+XtQuEA= |
| Xref | csiph.com comp.sys.acorn.programmer:6632 |
Show key headers only | View raw
In article <5ccaee3398bob@sick-of-spam.invalid>,
Bob Latham <bob@sick-of-spam.invalid> wrote:
> The nearest I've got is to intercept vector 5 and if you double
> click a Basic file it will set the variable and you're good to go.
Have you have done an OS_Claim,5 in another program, before
double-clicking the program you are wanting to find the name of?
Beware that adds an overhead on EVERY command that is issued until the
OS_Release,5. And there can be many hundreds of them!
> But, if you drop into Basic and then load the basic program then
> no-go.
That is to be expected...
Double-clicking a any file (BASIC, Absolute, Utility, Command, Jpeg,
etc) will result in an command:
Run <pathname><filename>
This issues another command depending on the hex file type. For a
BASIC program this is:
@RunType_FFB <pathname><filename>
The Alias$@RunType_FFB for a BASIC program then issues command
Basic -quit "<pathname><filename>"
All these three are OS commands, and will pass through the OS_CLI
vector 5, and will be seen by anything intercepting that vector at
that time.
However, when in interactive BASIC, a
LOAD filename
is a BASIC command, and NOT an OS command, so it is not seen by the
OS_CLI vector. The last OS command issued is just BASIC.
Issuing a *command or OSCLI("command") would be an OS command.
Note that all the OS commands issued can be seen easily if my Reporter
is running - see www.avisoft.f9.co.uk
> I'm concluding this can't be done.
Yes it can, if what you want is the filename of the running program...
If the program that is actually running issues an OS_GetEnv SWI you
get returned the address of the OS command which started that program.
It will include the full <pathname><filename>, and is exactly the same
as passed to OS_CLI and passes through the vector.
Therefore...
If you have double-clicked a BASIC program <filename> it will show
Basic -quit <pathname><filename>
If in interactive BASIC it will still just show BASIC after a LOAD.
No Claim for OSCLI vector 5 is required.
Does that help?
--
Martin Avison
Note that unfortunately this email address will become invalid
without notice if (when) any spam is received.
Back to comp.sys.acorn.programmer | Previous | Next — Previous in thread | Next in thread | Find similar
Name of a program Bob Latham <bob@sick-of-spam.invalid> - 2026-04-16 17:34 +0100
Re: Name of a program Martin <News04@avisoft.f9.co.uk> - 2026-04-16 18:17 +0100
Re: Name of a program Bob Latham <bob@sick-of-spam.invalid> - 2026-04-16 19:18 +0100
Re: Name of a program Martin <News04@avisoft.f9.co.uk> - 2026-04-16 22:29 +0100
Re: Name of a program Harriet Bazley <harriet@bazleyfamily.co.uk> - 2026-04-17 10:45 +0100
Re: Name of a program Theo <theom+news@chiark.greenend.org.uk> - 2026-04-17 11:43 +0100
Re: Name of a program Bob Latham <bob@sick-of-spam.invalid> - 2026-04-17 12:59 +0100
Re: Name of a program Martin <News04@avisoft.f9.co.uk> - 2026-04-17 16:52 +0100
Re: Name of a program Bob Latham <bob@sick-of-spam.invalid> - 2026-04-17 20:15 +0100
Re: Name of a program Martin <News04@avisoft.f9.co.uk> - 2026-04-17 23:24 +0100
Re: Name of a program Bob Latham <bob@sick-of-spam.invalid> - 2026-04-18 10:08 +0100
Re: Name of a program Theo <theom+news@chiark.greenend.org.uk> - 2026-04-18 10:56 +0100
Re: Name of a program Martin <News04@avisoft.f9.co.uk> - 2026-04-18 11:13 +0100
Re: Name of a program Bob Latham <bob@sick-of-spam.invalid> - 2026-04-18 13:50 +0100
Re: Name of a program Bob Latham <bob@sick-of-spam.invalid> - 2026-04-18 15:29 +0100
Re: Name of a program Martin <News04@avisoft.f9.co.uk> - 2026-04-18 16:30 +0100
Re: Name of a program Theo <theom+news@chiark.greenend.org.uk> - 2026-04-18 17:54 +0100
Re: Name of a program Martin <News04@avisoft.f9.co.uk> - 2026-04-18 18:06 +0100
Re: Name of a program Martin <News04@avisoft.f9.co.uk> - 2026-04-18 18:51 +0100
Re: Name of a program Bob Latham <bob@sick-of-spam.invalid> - 2026-04-18 19:08 +0100
Re: Name of a program Martin <News04@avisoft.f9.co.uk> - 2026-04-18 19:36 +0100
Re: Name of a program Bob Latham <bob@sick-of-spam.invalid> - 2026-04-17 12:08 +0100
Re: Name of a program Harriet Bazley <harriet@bazleyfamily.co.uk> - 2026-04-17 14:12 +0100
Re: Name of a program Tank <webmaster@tankstage.co.uk> - 2026-04-17 15:09 +0100
Re: Name of a program Harriet Bazley <harriet@bazleyfamily.co.uk> - 2026-04-17 19:35 +0100
Re: Name of a program Bob Latham <bob@sick-of-spam.invalid> - 2026-04-17 20:17 +0100
Re: Name of a program Martin <News04@avisoft.f9.co.uk> - 2026-04-17 23:30 +0100
Re: Name of a program Steve Fryatt <news@stevefryatt.org.uk> - 2026-04-18 11:39 +0100
Re: Name of a program Bob Latham <bob@sick-of-spam.invalid> - 2026-04-18 13:55 +0100
csiph-web