Hello my friends!
I have a difficulty.
I need to execute tasks in a Loop with different information. I created a code, but I don’t want to determine the number of repetitions, I want it to run from the first to the last line of whatever is inside the CSV.
I managed to do this, but the Loop always repeats the first line.
In this example, the CSV has 4 lines, it repeats the first line 4 times.
What could be wrong and how can I make it execute all the lines?
{
"Name": "DISTRIBUIÇÃO DE VAGA - POLO - V 1.0",
"CreationDate": "2024-8-8",
"Commands": [
{
"Command": "csvRead",
"Target": "base - vinculação de polo.csv",
"Value": "",
"Description": ""
},
{
"Command": "executeScript_Sandbox",
"Target": "return 1",
"Value": "currentRow",
"Description": ""
},
{
"Command": "while_v2",
"Target": "${currentRow} <= ${!csvReadMaxRow}",
"Value": "",
"Description": ""
},
{
"Command": "store",
"Target": "${currentRow}",
"Value": "!csvReadLineNumber",
"Description": ""
},
{
"Command": "type",
"Target": "xpath=//input[@name='curso[${!COL1}][polos][${!COL3}][nu_vagas]']",
"Value": "${!COL4}",
"Targets": [
"xpath=//input[@name='curso[${!COL1}][polos][${!COL3}][nu_vagas]']"
],
"Description": ""
},
{
"Command": "executeScript_Sandbox",
"Target": "return ${currentRow}+1;",
"Value": "currentRow",
"Description": ""
},
{
"Command": "endWhile",
"Target": "",
"Value": "",
"Description": ""
}
]
}