Illegal call expression or index expression

A value in parentheses follows an expression that is not a procedure, property, or array.

The following code can generate this error.

Dim testVariable As Object = Nothing(1)

Because Nothing does not take arguments or indexes, you cannot use it with parentheses.

Error ID: BC32303

To correct this error

  • Remove the parentheses and any value they contain.

See Also

Tasks

How to: Call a Procedure that Returns a Value

How to: Call a Procedure that Does Not Return a Value

How to: Put a Value into an Array

How to: Get a Value from an Array

How to: Put a Value in a Property

How to: Get a Value from a Property