Post Reply 
How to use AVars and AFiles
05-26-2015, 11:05 PM
Post: #1
How to use AVars and AFiles
I have 2 Lists occupying memory. They were both created from the home screen. Their names are Gasses and GasVars. Gasses has 42 values, GasVars has 32 values. They are both used by an App I created. I have been unable to figure out how to move the contents of these 2 Lists to either an AVars or AFiles, so I can send them along as part of the App. Is a List considered a Var or a File? Does anyone know how to do this? Thanks
rcf
Find all posts by this user
Quote this message in a reply
05-27-2015, 01:31 PM (This post was last modified: 05-27-2015 01:32 PM by Tim Wessman.)
Post: #2
RE: How to use AVars and AFiles
Either and both.

Make sure the app is running, then do AVars("YourAppVarName"):=Gasses or AFiles("YourFileName"):=GasVars

The difference comes in the way you interact with them. A file cannot be used and accessed directly. You will need to store into a variable to use it. The file *will not* take up the limited system RAM you have except for the instant you are using it. A variable will *always* stay in memory and be taking that RAM even when your app is not in use.

LOCAL mylist;
mylist:=AFiles("YourFileName");
mylist(1)
...

vs

YourVarName(1)
...

So basically it boils down to how large your variables are. If you are trying to store 3MB of data for example, a file would most likely be the way to go.

TW

Although I work for the HP calculator group, the views and opinions I post here are my own.
Find all posts by this user
Quote this message in a reply
Post Reply 




User(s) browsing this thread: 1 Guest(s)