I am using a For each row actvity where I loop for each row in a data table. Immediately before the For each row activity, I use the Excel application scope and then “Read Range” for one Excel worksheet.
Later on within this loop, I need to open the same source Excel worksheet, Execute a Macro, and then call a new variable created by this Macro in a Do while loop. I do this by calling the variable with row(“Column Name”).ToString.
The problem is, when I use Write Line to see what value is being passed in the Do while loop, it uses the original value (from the Excel Application scope outside of the For each row activity) and not the more recently called Excel Application Scope that executes the Macro.
How can I make sure the program, within my for each row loop, uses the new variable value that is updated by the Macro and not by the original excel value from outside the for each row loop?
Let me know if there is further clarification needed.