Visual Basic Scripting Edition  

Expected 'End'

You created a construct, but did not properly terminate it. The following table lists the VBScript constructs that must end with an End statement.

Construct Terminating Statement
Sub End Sub
Function End Function
If End If
Class End Class
With End With
Select End Select

To correct this error

See Also

Sub Statement | Function Statement