I have a short Obey file that I use to connect to my NSLU2 drive.
Here it is complete:
IfNTask "LanMan98 Filer" WimpTask <Root>.Network.!LanMan98.!Run
Connect98 NSLU2 nslu2 nslu2_1 david david
The first line is fine: it only invokes the LanMan98 filer if it
isn't already there. The second line works, but with a side effect:
if the drive is already mounted, it closes any directory display(s)
open on that drive. It's only an irritation, but I'd like to avoid
it if I can, presumably by checking first that NSLU2 is not already
mounted.
Dave
> Is it possible to programmatically discover if a drive is mounted via
> LanMan98?
That's a good question - if there is, I could add it to WaitUntil's
condition list.
It might be worth experimenting with WaitUntil - use it to wait until a file
exists on the LanMan98 mount (choosing a file you know to exist). In theory,
the file won't exist (from the point of view of your RISC OS computer) until
the drive is mounted. Adding an actual check for the mount would be better,
of course - but as a (temporary?) alternative, it might be worth a try.
http://www.softrock.co.uk/products/waituntil.html
--
Vince M Hudd - Soft Rock Software
http://www.softrock.co.uk
http://misc.vinceh.com
> In article <ab38d8cd50...@dsl.pipex.com>,
> Not sure if this helps but I use the following...
>
> | Is this disc available - can we see the $ directory
> |
> Set MyWork$Q No
> IfThere LanMan98#notypes::C.$ Then Set MyWork$Q Yes
> |
> | If not then load the disc.
> |
> If "<MyWork$Q>"="No" Then Filer_Run <DeskIcons$Dir>.C
> |
> | Close all the vaiable used.
> |
> UnSet MyWork$Q
> Filer_OpenDir LanMan98#notypes::C.$.Documents and Settings.
> HomePC.My Documents.Bob
Thanks, Bob, that will do nicely.
Dave