When performing any actions in Maya, you are executing Maya commands. When
The Maya commands executed when moving an object using the move tool are very different from those executed when setting attributes through the Attribute Editor or the Channel Box.
Next, you translate the cube using the Channel Box to observe the Script Editor history and compare it to the Script Editor history created by using the move tool.
To observe the Script Editor history created when using the Channel Box
The following script history appears in the upper section of the Script Editor
setAttr "nurbsSphere1.translateX" 5;
When using the Channel Box to move objects, you are using the setAttr command to set the attributes of the selected object.
To observe the history created with the Move Tool
The following script history appears in the history section of the Script Editor:
move -r -5 0 0;
Do not be concerned if your values are not be the same for this example.
The move command modifies the translate attributes for all selected objects.
The move command was executed with the relative flag. Flags have short forms and long forms: -r is the short form of the -relative flag.
The move command with the relative flag adds the values after the flag to the current XYZ co-ordinates of the object.
delete;
Pressing the delete key on your keyboard has the same functionality as the delete command in most situations.
When the Attribute Editor or the Channel Box is used to modify the attributes of the selected object, the recorded script contains the setAttr command referring to the initially selected object. The move tool or the move command must be used to modify the attributes of an object if the script is to be reused on another object.