Option Strict On requires all variable declarations to have an 'As' clause

A declaration contains a declared variable without an As clause. When Option Strict is On, every variable, property, procedure argument, and function return must be declared with an As clause to specify its data type; for example, Dim MyNum As Short.

Error ID: BC30209

To correct this error

  1. Check to see if the As keyword is misspelled.

  2. Supply an As clause for the declared variable, or turn Option Strict Off.

See Also

Concepts

Variable Declaration in Visual Basic

Reference

Option Strict Statement