Empty parentheses not legal on: <name>

You included empty parentheses in referring to a variable of type Variant or an undefined function or sub (which LotusScript® interprets as a reference to an implicitly declared variable of type Variant). For example:

Dim anArray(1 To 3) As Integer
Dim varV As Variant
varV() = anArray()        ' Illegal
varV = anArray()          ' Legal
varV = anArray            ' Legal
Dim X As Integer
X% = varV()               ' Illegal
X% = varV                ' Legal

Remove the parentheses from the Variant variable.