Hello everyone,
I need your help.
The range we will work on is the range: ("R2:T" & Last line).
This range is quite large, which is why I allow myself to ask you for a fairly fast loop, like (UBound) or (Dictionary).
The purpose of my request is to swap the rows of columns: "R", "S" and "T", I will explain the procedure later.
The initial table looks like this:
This is what I want to do, is to create a loop that will swap all the cells of the 3rd line "R3", "S3" and "T3" with all the cells of the 2nd line: "R2 ", "S2" and "T2". Then we display a Msgbox with the number of the passage of the loop.
Here is the result of the first pass of the loop:
On the second pass of the loop, we will swap all the cells of the fourth line "R4", "S4" and "T4" with all the cells of the 2nd line: "R2", "S2" and " T2". Then we display a Msgbox with the number of the passage of the loop
Here is the result on the second pass of the loop:
And so on until the last line of the range.
I remain at your disposal for any additional information.
Cheers.
I need your help.
The range we will work on is the range: ("R2:T" & Last line).
This range is quite large, which is why I allow myself to ask you for a fairly fast loop, like (UBound) or (Dictionary).
The purpose of my request is to swap the rows of columns: "R", "S" and "T", I will explain the procedure later.
The initial table looks like this:
Classeur1 | |||||
---|---|---|---|---|---|
R | S | T | |||
1 | Jeune | Père | Mère | ||
2 | 876-054/2004 F | B1 | C1 | ||
3 | 876-025/2006 F | B2 | C2 | ||
4 | GUP14-028/2006 F | B3 | C3 | ||
5 | GUP14-041/2006 M | B4 | C4 | ||
6 | GUP14-011/2007 F | B5 | C5 | ||
7 | AMA55-014/2007 M | B6 | C6 | ||
Feuil1 |
This is what I want to do, is to create a loop that will swap all the cells of the 3rd line "R3", "S3" and "T3" with all the cells of the 2nd line: "R2 ", "S2" and "T2". Then we display a Msgbox with the number of the passage of the loop.
Here is the result of the first pass of the loop:
Classeur1 | |||||
---|---|---|---|---|---|
R | S | T | |||
1 | Jeune | Père | Mère | ||
2 | 876-025/2006 F | B2 | C2 | ||
3 | 876-054/2004 F | B1 | C1 | ||
4 | GUP14-028/2006 F | B3 | C3 | ||
5 | GUP14-041/2006 M | B4 | C4 | ||
6 | GUP14-011/2007 F | B5 | C5 | ||
7 | AMA55-014/2007 M | B6 | C6 | ||
Feuil1 |
On the second pass of the loop, we will swap all the cells of the fourth line "R4", "S4" and "T4" with all the cells of the 2nd line: "R2", "S2" and " T2". Then we display a Msgbox with the number of the passage of the loop
Here is the result on the second pass of the loop:
Classeur1 | |||||
---|---|---|---|---|---|
R | S | T | |||
1 | Jeune | Père | Mère | ||
2 | GUP14-028/2006 F | B3 | C3 | ||
3 | 876-054/2004 F | B1 | C1 | ||
4 | 876-025/2006 F | B2 | C2 | ||
5 | GUP14-041/2006 M | B4 | C4 | ||
6 | GUP14-011/2007 F | B5 | C5 | ||
7 | AMA55-014/2007 M | B6 | C6 | ||
Feuil1 |
And so on until the last line of the range.
I remain at your disposal for any additional information.
Cheers.