I've written a Programm which shall be started with or without Parameters. Without Parameters, a setup-form is loaded, with Parameters, a FTP-Transfer-form is loaded. I've included a Sub main-procedure and deactivated the Framework and everything works fine but only within the IDE. If I start the compiled exe-file, the Sub main is noz executed.
Here's the code:
Expand|Select|Wrap|Line Numbers
- Public Sub Main()
- Dim lDoSetup As Boolean = False
- Dim aCom As String() = Environment.GetCommandLineArgs
- If aCom.Length > 0 Then
- If aCom.Length = 1 Then
- If Debugger.IsAttached Then
- lDoSetup = True
- End If
- End If
- Else
- lDoSetup = True
- End If
- If lDoSetup Then
- MsgBox("Setup ist True")
- End If
- If lDoSetup Then
- Application.Run(New SetupFRM)
- Else
- Application.Run(New FTPFRM(aCom))
- End If
- End Sub
Hay anybody any idea what might cause this.
Best regards
Thomas