07 February 2019, 13:45 | #1 |
Registered User
Join Date: Jan 2017
Location: Antwerp / Belgium
Posts: 189
|
AmigaDOS: Open file with "default tool" from CLI
AmigaDos question.
Classic OS (3.1) Is there a way to open a file using it's default tool from CLI? Basically I want to open an image in dpaintIV when the system boots. I would imagine that you could execute something like "dpaint pic.iff" but that just opens dpaint. When I specify dPaint als default tool in the file icon, this works when I click the icon, so clearly dPaint can open a file at startup. How do I do the same thing from CLI? Or how does this "default tool" thing in WorkBench work exactly behind the scenes? |
07 February 2019, 14:02 | #2 |
Banned
Join Date: Aug 2005
Location: London / Sydney
Age: 47
Posts: 20,420
|
Dpaint load <path>/<filename>
|
07 February 2019, 14:31 | #3 |
Registered User
Join Date: Jun 2009
Location: Dublin, then Glasgow
Posts: 6,369
|
Yep, you can usually run the program from the CLI with the path of the file you want to open as an argument. Behind the scenes, the default tool setting in icons only applies within Workbench, not in the Shell or anywhere else. It simply tells Workbench to launch the named program with the icon you've opened as an argument.
|
07 February 2019, 15:02 | #4 |
Registered User
Join Date: Jan 2017
Location: Antwerp / Belgium
Posts: 189
|
|
07 February 2019, 15:17 | #5 |
Banned
Join Date: Aug 2005
Location: London / Sydney
Age: 47
Posts: 20,420
|
No problem
When stuck trying to work out the syntax / options for a program; always a good idea to use "?": |
08 February 2019, 02:14 | #6 |
Coder/webmaster/gamer
Join Date: Oct 2001
Location: Canberra/Australia
Posts: 2,651
|
WBRun pic.iff
would be another way of doing it. |
08 February 2019, 08:47 | #8 |
Coder/webmaster/gamer
Join Date: Oct 2001
Location: Canberra/Australia
Posts: 2,651
|
Oops, didn't notice that he said he was still on OS3.1.
|
08 February 2019, 09:16 | #9 |
Registered User
Join Date: Jan 2017
Location: Antwerp / Belgium
Posts: 189
|
Excellent Excellent Excellent.
Now I don't even have to know what program is associated with the file from CLI. Very handy for mod files e.g. Thanks! (apparently it's also provided by BetterWB, so it was there on my system already without me knowing) S |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
"Open with" tool for iconless, non-executable files in workbench 3.1? | Yulquen74 | support.Apps | 6 | 22 June 2023 15:06 |
"LIST: Unable to open redirection file" Returncode 10 | Foebane | support.Apps | 25 | 17 July 2018 17:26 |
"Unable to open your tool 'Installer' "-Workbench 3.1 | Mr B | support.Apps | 7 | 31 March 2011 00:14 |
Unable to open your tool "directory opus' | skeediddley | support.Apps | 3 | 04 December 2010 03:09 |
"Unable to open your tool" | S. Campbell | support.WinUAE | 31 | 12 September 2004 20:39 |
|
|