I don't recommend using StringSplit, because it will be removed in AHK v2. I would use StrSplit instead, and would recommend to use BoBo's example above, rather than this example here, which I have provided only to show how it's done:
Code: Select all
q::
TestString=102/708
StringSplit, OutputArray, TestString, /
Variable1:=OutputArray1 ;Variable1:=102
Variable2:=OutputArray2 ;Variable2:=70
MsgBox, % Variable1 " " Variable2
TestString=102/708
StringSplit, OutputArray, TestString, /
Variable1=%OutputArray1% ;Variable1:=102
Variable2=%OutputArray2% ;Variable2:=70
MsgBox, % Variable1 " " Variable2
TestString := "102/708"
StringSplit, Variable, TestString, /
MsgBox, % Variable1 " " Variable2
return
[2017th post: the current year]