Imports System

Public Class Test
	Public Shared Sub Main()
		Dim texto As String = "if Argumento1 = Argumento2 ( --statements; );"

        Dim ifIndice As Integer = texto.IndexOf("if")
        Dim igualIndice As Integer = texto.IndexOf("=")

        Dim ifLen As Integer = Len("if") + 1

        Dim argumento1 As String = texto.Substring(ifIndice + ifLen, igualIndice - ifLen)
        Dim argumento2 As String = texto.Substring(igualIndice + 2, texto.IndexOf(" (") - igualIndice - 1)
        Console.WriteLine(String.Format("Arg1: {0}, Arg2: {1}", argumento1, argumento2))
        Console.ReadLine()
	End Sub
End Class