Clears the value of a single variable. Also clears all the filters that were set if the variable is a record and resets the key to the primary key.
The identifier (variable) of any C/AL data type, including simple and composite data types. The following rules apply when you run the CLEAR function:
1. A number variable is set to 0 (zero)
2. A string variable is set to empty string
3. A date variable is set to 0D (undefined date)
4. A time variable is set to 0T (undefined time)
5. A Boolean variable is set to FALSE
1. A number variable is set to 0 (zero)
2. A string variable is set to empty string
3. A date variable is set to 0D (undefined date)
4. A time variable is set to 0T (undefined time)
5. A Boolean variable is set to FALSE
For Eg:
Consider a Variable 'Name' which has value-'xyz'.
Name := 'xyz';
CLEAR(Name);
No comments:
Post a Comment