Code: Select all
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim i As Integer
Dim u As Integer
Dim cmd As String = Command()
' If cmd.Contains("-res") Then
If cmd.Contains("-res(" & i & "," & u & ")") Then
Me.Width = i
Me.Height = u
Else
MessageBox.Show("Resolution not supported", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error)
'Me.Close()
End If
' End If 'cmd.Contains("-res")
End Sub