HP Forums

Full Version: programs disappearing from toolbox menu
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I first had a test program called TEST that was in home mode.
Then I tried to add a test CAS program into that program called TCAS by typing:
etc, etc...

I had the conventional EXPORT TEST() above this with a different program in it. I like to group multiple programs into one "program file" as it were.....is easier to organize.

However, this TCAS program didn't show up in the toolbox menu.
So, I decided to delete the TEST program entirely, as it's one I use to create test programs only.
So, I then tried to create a new program called TCAS, but it said that TCAS already existed (this was the first problem I encountered).

So, then I decided to create a new one called TEST instead, with the CAS box checked.
I did this, and wrote the program like the TCAS example above (but was called TEST instead).
However, in the toolbox menu, the TEST program doesn't show up??????

How do I correct this? I'm fine with deleting that program and restarting, but I think however the cataloging is done, it's messed up somehow. Is there some kind of way I can purge TEST and TCAS after I delete the program to properly remove everything to do with them and then try creating a new program again?

Please help. Thanks in advance.
I can find these symbols using shift-mem and selecting CAS-vars. Then I can select view and I can see TCAS and TEST. How do I delete it from the CAS-vars view? I don't see a delete option....
This might solve my problem and clean things up after I delete the programs....
You could (see help for more info):

purge(var), or
You can use Memory Manager (shift mem) select CAS Vars, there is a delete option.
There is a reset, but no delete option in CAS-vars.
I tried reset and it seemed to delete them.
So, I went back and recreated my CAS program TEST.
It still doesn't appear in the menu. I need to look at restart and purge perhaps next.
I tried both purge and restart after deleting TEST again.
I created a new CAS program TEST.
...and it still doesn't show up in the USER menu????????????
Any ideas?
It shows up in the shift-programs and from mem-programs-view it also shows up. It's just in the toolbox-user menu that it doesn't show up.
Anyone encounter this before. I've been trying to search the archives but haven't found it but i vaguely remember seeing this problem coming up before with someone else....
I deleted TEST again and created a new home type program called TEST and it showed up on the USER menu!
However, when I deleted this and created another TEST but this time a CAS program, again, it doesn't show up on the USER menu?
I then created another new CAS program called PCAS, and again, it doesn't show up on the USER menu....
It is that CAS programs don't show up there?
I tried restoring a backup.
Then created a new CAS program, and it doesn't show up on the USER menu either....so what's up?
CAS-functions don't show up in the Toolbox menu.
They show up in Vars under Cas.
Why on earth would they make such an inconsistent system....that's bad design!

It is actually a completely consistent design.

The issue is that the cas does not have the concept of a program source file. You cannot have a file that contains a bunch of related functions, variables, and so on. Additionally, every thing from the cas perspective is a variable containing an object. In this case, you have a variable containing a function definition.

It truly is a variable. You can delete it, store into it, and do everything you'd expect from any other variable.

The purpose of the #cas directive is to throw the compiler into a mode where it begins executing your lines as if you were typing them on the cas screen. This does not mean your functions are protected from deletion, or having the user override them. They are just variables stored into the cas memory.
But from a user's perspective it IS inconsistent. I mean you worry about using ++/-- as being insconsistent, whereas this is 1000000 times more inconsistent. When I write a program, I expect it to be stored with my programs.....
The Prime's CAS programs are stored as variables and have been defined that way by the authors. Understanding how CAS programs are defined, allows their proper use. Take any command from the command set, and apply the same philosophy, understanding its functionality allows its proper use.

The hp Prime doesn't hold itself out to be any particular programming language equivalent, so there is no compelling reason to place any external restrictions on its design. Validating "expectations" is part of the learning curve.

I'm OK with this design.
From the CAS perspective, it cannot distinguish between a single line function x^2 or a 1000 line complicated function. They are identical.

What the program catalog contains is a source file. Within that source file, you can declare variables, cas objects, local and global functions, and a few other things. Are all those programs since they were defined in a program source file?

Could you please explain the macro thing you keep advocating for? I still don't understand if you mean a c style preprocessor, or something else.
I'd much prefer if the define way of writing programs were true macros....like C or equivalent....simple text substitution....
How or where would this apply? Would you expect it to happen everywhere? Should the use be allowed to define 1 and -1 and anyplace 1 appears it would treat it as -1 silently?

What benefit would it give you over what is already there? Are you just looking for a way to save a few keystrokes on program creation?
For example, it takes quite a bit of time to write programs (one of the awkward things of having CAS programs not being accessible the same way as other programs)....I like the interface in general and the way we can grab definitions from the menus.....helps speed up program writing.
Now I tried to create x:=x+1 using define, and was supremely disappointed to discover this was a program.....as it slows the process considerably....I was trying to put something like inc(x) or x++ as a macro. Mostly to speed up program writing and to put commonly used expressions together but not in a program as often I need the speed....and a macro would be much faster than a program for a short definition. Though I guess that depends on the implementation.
Reference URL's