I would like to evaluate a section several times for different values of some variables. I can evaluate it once with a simple command, but not in a loop.

To evaluate it only once, this code works

```
aValue = 6; activateB = True;
evaluateSection["mySection"]
```

where somewhere in the notebook there is a section called "mySection" containing this code

```
If[activateB , aValue * 100, aValue];
%//Print
Pause[2]
```

And the code of `evaluateSection` is

```
Clear[evaluateSection]
evaluateSection[title_String]:=Module[{titleCell},
    titleCell = SelectFirst[Cells[],
    MatchQ[NotebookRead[#],
    Cell[title,"Title"|"Subtitle"|"Chapter"|"Section"|"Subsection"|"Subsubsection",___]]&];

    SelectionMove[titleCell,All,CellGroup];
    SelectionEvaluate[EvaluationNotebook[]]
]
```

The code that does not work for me (it ignores the Pause, spitting all the `namerun` at once (correctly) but does not evaluate the section with the required input values)

```
Do[
    aValue = $aValue; activateB = $activateB;
  
    evaluateSection["mySection"];
    namerun = StringJoin[{"A", aValue, "B", If[activateB, "1", "0"]} // Map[ToString]];
    Print[namerun];

    ,{$aValue,{0,2,4}}
    ,{$activateB,{True,False}}
]
```