HP Forums

Full Version: How to make cas-mode program visible when choosing from program library
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I'm creating a program in cas mode with (when creating a program, I checked on cas check box). Then I work in cas mode. When accessing the program, I press program library button (which is mem key) > User

ิI can't find the program I wrote. I found only the program I wrote which are not in cas mode.

How can I make my program in cas mode visible from User list.

Note : I can find it in Catlg.
Hello,

The way CAS works makes it difficult to find programs... in a list...
Furthermore, most programs have sub functions, and in the CAS, there is no way to distinguish main program entry from sub functions...

The best solution (should your program allow it), would be to write a PPL "header" for your cas program and set that "header" or "calling function" as exported.

cyrille
Thank you, Cyrille for your help.

I'm quite new to HP Prime programming. Not get what you try to explain.

Let's say, my program written in cas mode is like this:

#cas
Test123(AB,CD):=
BEGIN
RETURN AB*CD;
END;
#end


what should I do (or added in the code) to make the program visible in the list
It is visible, under "VARS->Cas->Program"

The problem is that cas "programs" are actually variables containing an object that happens to contain something that executes. You can delete it, store something else in it, etc. It really is just a variable.

There is no difference unfortunately between f(x):=x^2 and something much more complicated. Would you want f(x)=x^2 to appear in your "programs" area?
Just create a wrapper as suggested by Cyrille. Create your CAS program with using whatever program name you want and just add an 'h' in front for a HOME program that calls your CAS program. Example:

Code:
#cas
BEGIN CASPRG():=
  return(2-1);
END;
#end;


EXPORT hCASPRG()
BEGIN
  CASPRG();
END;
I like setting up my own pop-up program menu, assigned to a user key. Here's an example from Eddie's blog that does exactly that:

http://edspi31415.blogspot.com/2017/11/h...st-of.html

-Victor
Reference URL's