Q(uick)BASIC Keyword: ANY

Quick View

ANY Clause

When used as the variable type in an AS type clause that is part of a procedure declaration, ANY disables type checking for that parameter

Worth knowing

Useful and cross-version information about the programming environments of QBasic and QuickBasic.

Syntax
  • DECLARE {FUNCTION | SUB} name [([parameterlist])]
Description/Parameter(s)
name The name of the procedure.
parameterlist One or more variables that specify parameters to be passed to the procedure when it is called:
variable[( )] [AS type] [, variable[( )] [AS type]]…
variable A Basic variable name.
type The data type of the variable (INTEGER, LONG, SINGLE, DOUBLE, STRING, or a user-defined data type). ANY allows any data type.

DECLARE is required if you call SUB procedures without CALL. QBasic automatically generates DECLARE statements when you save your program.

Example

The program REMLINE.BAS illustrates declaring FUNCTION and SUB procedures. To view or run this program, load REMLINE.BAS using the Open command from the File menu.

Syntax
  • variable AS ANY
Description/Parameter(s)

variable: any data type

See also:

Syntax
  • variable AS ANY
Description/Parameter(s)

variable: any data type