The Rename Command

rename.png

Command Summary

Renames a variable into another one

Command Syntax

Rename var1,undefinedvar2

Menu Location

Catalog Menu

Calculator Compatibility

This command works on all calculators.

Token Size

X byte(s)

The Rename command allows you to rename a defined variable to an undefined variable. This is useful if you want to store the value of a variable into another variable, although the Store command is more commonly used for that purpose.

Rename a,b

The above code would run when "a" is a defined variable and "b" is an undefined variable. That means that if both "a" and "b" were defined, or if "a" was undefined and "b" was defined, it would not work (it would give you error 960).You would get an error if you try to redefine an already defined variable.

Advanced Uses

The Rename command can also be used for strings. The below code would store the text in Str1 to "a".

Rename str1,a

Error Conditions

960 - Undefined variable happens when there is an undefined variable.

270 - Duplicate variable name happens when there is a duplicate variable name.

Related Commands

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-Noncommercial 2.5 License.