Movestr Command
Obsolete
This command is replaced by the Move command.
Purpose
To move data to a variable without evaluation or any checking as to its eligibility for a particular data type.
Syntax
movestr
value
to
variable
What It Does
The movestr command moves the value of value to variable. Since any string of characters qualifies as a string, it does no type checking or evaluation. movestr does not evaluate expressions, although it can move strings that are expressions.
When a move command addresses an explicit variable of type String, the compiler automatically replaces the move command with a movestr command. Where you know that data is being moved to a variable of type String, using movestr instead of move can save a very small amount of time per command at compile time.
Notes
-
movestrnever generates a type checking error such as DataFlex Error 51 (Bad format in expression (operand)), regardless of the actual type ofvariable. -
movestrdisables DataFlex's automatic type checking ofvariables, so if youmovestrto a Date, Integer, Real, or Number typevariable, no error will be declared at compile time, nor will one be declared at runtime. This effect is harmless, so long as you intend it.