To completely quote the readme:

SetUpEditor is one of the most useful commands to BASIC programmers and I have always griped that I could not use it for other variable types like strings and matrices. Guess what I did?

What does it do?
Like the SetUpEditor does for lists, this will check for variables. If the variable doesn't exist, it gets created, or if it is archived, it gets unarchived.

How do I use it?
The line directly after calling this program contains a string of variables. The variable types that work are:
-Strings
-Pictures
-Equations
-Programs
-Matrices
So in practice, what you would do:

Code:

:Asm(prgmSETUPVAR
:[B],prgmALPHA,Pic2,Pic3,Str1,Str7,[C]
:<<rest of code>>


Notes:
Size? 208 bytes
This will try to work for other variables, but it will fail most likely and it will make you lose RAM and crash.

Download
What a clever idea! SetUpEditor is certainly a superb way for TI-BASIC programmers to maintain custom lists without risking ERR:UNDEFINED errors, so this seems like a good way to extend the concept. I was going to ask why you put the list of variables on the line after the subprogram call instead of before, until I realized that in Ans it would just be a series of unhelpful processed values, not to mention triggering those Undefined errors that it is meant to prevent. Good work.
Thanks Smile I had completely forgotten about this program until now, but it has been pretty useful. I hope it is useful to others!
I'm sure it will be. By the way, you should always link to the ticalc.org file pages of your programs, not the direct zip, because hotlinking sends you back to the folder page. And don't forget to give the Cemetech archives some love. Wink
This is an awesome idea, I have two thoughts though:
1. Why not let it work on list types, too? I know that's what SetUpEditor is for, but this would make it so it can all be done in one call.
2. I feel like it would be more intuitive if the code were like this:

Code:
:"[B],prgmALPHA,Pic2,Pic3,Str1,Str7,[C]
:Asm(prgmSETUPVAR
:<<rest of code>>
Or, at least, it would make it follow a more common paradigm.
Mmm, I'd second that request; hopefully it wouldn't make the code too much more complex. I'm not sure what Xeda is doing to parse the list of variables, but I can't imagine make Ans be a string containing the list would overly complicate things.
The reasons for why I didn't use the string idea were:

-It uses more memory (not that big of a deal)
-This method seems more like the SetUpEditor command where the arguments come after the function
-I didn't want it to mess with Ans (main reason)

Also, the program has been out for a while, actually, and has been used :[

As for working with lists, it actually works for L1,L2,...L6 and other hacked lists, but I didn't add support for named lists. When I get some time, I'll definitely try to add support for it Smile Hopefully it won't take me a year and a half, this time >.>
Xeda112358 wrote:
The reasons for why I didn't use the string idea were:

-It uses more memory (not that big of a deal)
-This method seems more like the SetUpEditor command where the arguments come after the function
-I didn't want it to mess with Ans (main reason)
Ah, ok, in that case it makes sense then, and I'd keep it how it is.

Xeda112358 wrote:
As for working with lists, it actually works for L1,L2,...L6 and other hacked lists, but I didn't add support for named lists. When I get some time, I'll definitely try to add support for it Smile Hopefully it won't take me a year and a half, this time >.>
What are hacked lists? Is that like how you have have 255 picture vars?
Yes, basically. They aren't typically used since you can give lists custom names, but they are possible.
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement