HELP with WHEN LOOP Please
I have a csv file with any number of rows in it.
I can read a row if I specify the row and then split the string to create a command line based on the data in that row and thus execute it.
However I don't want to do a for because each time I add a row I would need to modify the script.
example .csv file
data1,data2,data3,data4
data1,data3,data3,data4
code I have so far:
#include <GUIConstants.au3>
#include <string.au3>
$file = FileOpen("test.csv", 0)
If $file = -1 Then
MsgBox(0, "error", "File doesn't exist or can't be read")
Exit
EndIf
$string = (FileReadLine($file, 1))
$input = StringSplit($string, ",", 1)
$value1 = $input[1]
$value2 = $input[2]
$value3 = $input[3]
$value4 = $input[4]
$Commandline = "Test.exe " & "-dll "& $value1 & " -name " & $value2 & " -xml " & $value3 & " -in " & $value4
I am basically automating a Test Cycle with this process.
Any help in getting the When or suggestiont would be great!
I have a csv file with any number of rows in it.
I can read a row if I specify the row and then split the string to create a command line based on the data in that row and thus execute it.
However I don't want to do a for because each time I add a row I would need to modify the script.
example .csv file
data1,data2,data3,data4
data1,data3,data3,data4
code I have so far:
#include <GUIConstants.au3>
#include <string.au3>
$file = FileOpen("test.csv", 0)
If $file = -1 Then
MsgBox(0, "error", "File doesn't exist or can't be read")
Exit
EndIf
$string = (FileReadLine($file, 1))
$input = StringSplit($string, ",", 1)
$value1 = $input[1]
$value2 = $input[2]
$value3 = $input[3]
$value4 = $input[4]
$Commandline = "Test.exe " & "-dll "& $value1 & " -name " & $value2 & " -xml " & $value3 & " -in " & $value4
I am basically automating a Test Cycle with this process.
Any help in getting the When or suggestiont would be great!