How to run apps in different directory?
|
10-13-2014, 02:30 AM
Post: #1
|
|||
|
|||
How to run apps in different directory?
Is it possible?
I want to stick all of my custom made "toggle" apps in a folder, but still be able to run them from the CUSTOM menu. Is there some sort of PATH (like on Windows and Linux) I can add the apps folder too? |
|||
10-13-2014, 03:02 AM
Post: #2
|
|||
|
|||
RE: How to run apps in different directory?
Identify the calculator for which you seek this information.
|
|||
10-13-2014, 03:20 AM
Post: #3
|
|||
|
|||
RE: How to run apps in different directory?
(10-13-2014 02:30 AM)ohitsanazn Wrote: Is it possible? I'm assuming you're asking about the 50g since you've asked other questions about that calculator recently. While there's no PATH-like variable designated for the RPL systems, there is a default behavior defined where the operating system will generally search in the current directory and work upwards through each parent when it attempts to find a referenced global variable (aka. user-stored object). As such, the only location that you could store all of your toggle apps for universal access is in the HOME directory (since that would be found from any location). Items stored in the HOME directory will usually be found simply by using their name as a reference, regardless of which directory the calculator is currently browsing. That's probably not what you had in mind, but there's several other options (some more advanced than others). Perhaps the easiest would be to store them in preferred location (eg. UTILS / TGL), then in the code for your CUSTOM menu you would simply run the program by placing its name prefaced by the parent directories in braces, then executing with EVAL as follows: Code: { HOME UTILS TGL PROG1 } EVAL Note that, when using this method, the current directory is changed to the one containing the referenced object. So you may want to take that into account in your code (see the PATH command). |
|||
10-13-2014, 04:11 AM
Post: #4
|
|||
|
|||
RE: How to run apps in different directory?
(10-13-2014 03:20 AM)DavidM Wrote:(10-13-2014 02:30 AM)ohitsanazn Wrote: Is it possible? This solution works, but is there a way to change the label of the soft key? 50g | 48g+ | 38g Former TI user -- still need to bust out the 84 on tests though |
|||
10-13-2014, 04:44 AM
Post: #5
|
|||
|
|||
RE: How to run apps in different directory?
(10-13-2014 04:11 AM)ohitsanazn Wrote: This solution works, but is there a way to change the label of the soft key? From the 50g Users Manual, page 20-4: Quote:Menu specification and CST variable So, yes, you can change the label simply by changing the string in the appropriate position of the list shown above ("label1", "label2", etc.). For example, if you wanted your custom menu to include two items ("foo" and "bar"), each of which executed different programs in the /UTILS/TGL subdirectory of your calculator, you might do something like the following: Code: { |
|||
10-13-2014, 06:48 PM
Post: #6
|
|||
|
|||
RE: How to run apps in different directory?
(10-13-2014 04:44 AM)DavidM Wrote:(10-13-2014 04:11 AM)ohitsanazn Wrote: This solution works, but is there a way to change the label of the soft key? Alright. I'm all squared out now. Thanks! 50g | 48g+ | 38g Former TI user -- still need to bust out the 84 on tests though |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 4 Guest(s)