In my form_load() I have this code:

...
If Not (Command = "") Then
MakeConnection
End If
...
...
...
End Sub

I do have a MakeConnection sub defined, but when I compile and run the app with a Command, an error comes up saying:

Runtime error '5':
Invalid procedure call or argument.

I've tried replacing the call to the MakeConnection sub with a MsgBox and it works, can I not call the sub like that? If so, could you tell me why not?