| ASCII | Index Level | assignment |
| Syntax | ASSIGNED( variable ) |
| Category | BASIC |
| Type | Function |
| Description |
determines if the variable has been assigned a value.
If the variable has an assigned value, a non-zero value (true) is returned. If no value was ever assigned, 0 (false) is returned. "assigned" can tell if common variables have been previously assigned. "assigned" works well in FlashBASIC subroutines called from the "call" Access processing code. It prevents files from being repeatedly opened and variables from continually being re-initialized. |
| Options | |
| See Also | CLEAR assignment statements & functions = COMMON |
| Example |
if not(assigned(fv.entity)) then file entity
This determines if the file.variable "fv.entity" has been assigned previously with the "file" statement. If it has not been assigned, the "file" statement is executed. |
| Warnings | Pick Systems advises programmers to not rely on the "assigned" function to return a specific non-zero value. Its exact value is undefined and may vary between implementations. |
| Compatibility | D3 7.0 AP |
| ASCII | Index Level | assignment |