C1023: Unexpected at global scope

Top  Previous  Next

Description:

The global scope may contain only declarations/definitions of procedures, variables, enumeration types and constants. This error occurs when some other statement is encountered at the global scope.

Example:

 

for i = 1 to 10 ' error C1023: Unexpected at global scope

next i

 

See Also

Understanding the Scope of Variables