Thread View: comp.sys.acorn.tech
4 messages
4 total messages
Started by M Y Ben Gershon
Tue, 15 Dec 1992 11:03
Re: Finding the CSD
Author: M Y Ben Gershon
Date: Tue, 15 Dec 1992 11:03
Date: Tue, 15 Dec 1992 11:03
31 lines
1533 bytes
1533 bytes
dbh@doc.ic.ac.uk (Denis Howe) writes: -banks_p@kosmos.wcc.govt.nz wrote: - --Set My$CSD <FileSwitch$<FileSwitch$CurrentFilingSystem>$CSD> - -mybg@doc.ic.ac.uk (M Y Ben Gershon) replied: - --I couldn't get this to work. Has anyone else had any luck with it? - --Nope. Nesting the variables doesn't work. - -Funnily enough, I've just done this. After my success doing it under -RISC OS 2, doing it under RO3 was just too easy (though still not as -easy as you would expect). From memory: - -Set FS <FileSwitch$CurrentFilingSystem> -SetEval CSD "<FS>:"+FileSwitch$<FS>$CSD - -The first command is only necessary to make the second one fit on one -line! Who knows, maybe by RISC OS 4 they'll have got it down to one, -easy to swallow, variable. :-) - -Anyone know a simpler way? --- -Denis Howe <dbh@doc.ic.ac.uk> I am sorry to disappoint you, but this does not work either! It remains constant and is not altered when the csd is changed. Michael Ben-Gershon mybg@doc.ic.ac.uk
Re: Finding the CSD
Author: banks_p
Date: Wed, 16 Dec 1992 00:46
Date: Wed, 16 Dec 1992 00:46
21 lines
1326 bytes
1326 bytes
In article <1gke2bINN2up@swan.doc.ic.ac.uk>, mybg@doc.ic.ac.uk (M Y Ben Gershon) writes: > dbh@doc.ic.ac.uk (Denis Howe) writes: [bits deleted] > -Set FS <FileSwitch$CurrentFilingSystem> > -SetEval CSD "<FS>:"+FileSwitch$<FS>$CSD > > I am sorry to disappoint you, but this does not work either! It remains > constant and is not altered when the csd is changed. Of course it doesn't. It is not a code variable. To do what you want would reqire writing some short assembler. This approach is designed to allow you to find out the CSD at a *particular point in time*. This is useful for Obey scripts that need to know the CSD or whatever but is by no means intended to be a continually updating CSD variable. And of course it is considerably simpler to do than repeated calls to OS_GBPB and popping up directory layers which was what was required under RO2. Philip
Re: Finding the CSD
Author: Jason O'Broin
Date: Thu, 17 Dec 1992 17:41
Date: Thu, 17 Dec 1992 17:41
25 lines
1622 bytes
1622 bytes
In article <1992Dec16.124633.1@kosmos.wcc.govt.nz>, banks_p@kosmos.wcc.govt.nz writes:
>In article <1gke2bINN2up@swan.doc.ic.ac.uk>, mybg@doc.ic.ac.uk (M Y Ben Gershon) writes:
>> dbh@doc.ic.ac.uk (Denis Howe) writes:
>[bits deleted]
>> -Set FS <FileSwitch$CurrentFilingSystem>
>> -SetEval CSD "<FS>:"+FileSwitch$<FS>$CSD
>>
>> I am sorry to disappoint you, but this does not work either! It remains
>> constant and is not altered when the csd is changed.
>
> Of course it doesn't. It is not a code variable. To do what you want
>would reqire writing some short assembler. This approach is designed to
>allow you to find out the CSD at a *particular point in time*. This is
>useful for Obey scripts that need to know the CSD or whatever but is by no
>means intended to be a continually updating CSD variable.
>
Would it not be possible to create a macro variable which did an eval as above?
I don't have access to a machine at the moment, so I can't play with the idea.
Jason
--
( Recommended Reading: Zen and the Art of Motorcycle Maintainance
Robert M. Pirsig )
Re: Finding the CSD
Author: Denis Howe
Date: Fri, 18 Dec 1992 13:57
Date: Fri, 18 Dec 1992 13:57
32 lines
1907 bytes
1907 bytes
Denis Howe <dbh@doc.ic.ac.uk> wrote: >Set FS <FileSwitch$CurrentFilingSystem> >SetEval CSD "<FS>:"+FileSwitch$<FS>$CSD In article <1gke2bINN2up@swan.doc.ic.ac.uk> mybg@doc.ic.ac.uk (M Y Ben Gershon) wrote: >I am sorry to disappoint you, but this does not work either! It >remains constant and is not altered when the csd is changed. Some people are never satisfied. :-) As Jason <J.P.OBroin@newcastle.ac.uk> noted, to get that effect you'd need to use SetMacro but I'm not sure even that would work, you might need SetMacroEval, which doesn't exist! Philip <banks_p@kosmos.wcc.govt.nz> was nearer the mark saying you need a code variable but this week's star prize goes to Good Ol' Owen "Who put the OS in RISC OS?" Smith or, as his friends call him, /G=Owen/S=Smith/O=SJ-Research/ADMD=INTERSPAN/C=GB/@mhs-relay.ac.uk, who mailed in response to my RISC OS 2 solution: >On RISC OS 3 (no snide remarks please I'm just being helpful) you can >do it as an OS_FSControl 37 (canonicalise name) of "@", or you can >build it up piecemeal using the various FileSwitch$* system >variables. The only time I want to know the CSD is in my desktop !Boot file so I can make everything independent of the location of the root directory. Here, my "static" solution is quite acceptable. -- Denis Howe <dbh@doc.ic.ac.uk> So Biggs, you're the idiot who bought all these IBM PCs. You're fired!
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads