Omnimaga

Calculator Community => TI Calculators => Axe => Topic started by: ACagliano on September 07, 2010, 12:36:26 pm

Title: Combining 2 AppVars into 1
Post by: ACagliano on September 07, 2010, 12:36:26 pm
I have two appvar, each containing a string of different (or possibly equal) length. Each string contains the names of programs to be searched for, separated by commas.

"appvA"->Str2A
"appvB"->Str2B

I want to combine the two into one, and check for any program names in common between the two, and if so, store it to the combined appvar only once. Any ideas?
Title: Re: Combining 2 AppVars into 1
Post by: Quigibo on September 07, 2010, 08:13:33 pm
Well, I'm not sure about the name checking, but to combine 2 ram appvars A and B into C, you can do this:

Code: [Select]
Return!If GetCalc("appvA")->A
Return!If GetCalc("appvB")->B
{A-2}r->X   .Size of A
{B-2}r->Y   .Size of B
Return!If GetCalc("appvC",X+Y)->C
Copy(A,C,X)
Copy(B,C+X,Y)
Delvar "appvA"
Delvar "appvB"