TheWennerWoman
Active Member
- Joined
- Aug 1, 2019
- Messages
- 301
- Office Version
- 365
- Platform
- Windows
Book1.xlsm | |||||||
---|---|---|---|---|---|---|---|
A | B | C | D | E | |||
1 | code1 | code2 | vx | source | flag | ||
2 | C5678 | 103000 | 100 | ZV0001 | |||
3 | X00001 | 145444 | 28 | ZV0001 | |||
4 | X00001 | 173000 | 20 | ZV0001 | |||
5 | X00001 | 199000 | 19 | ZV0001 | |||
6 | X00001 | 212000 | 20 | ZV0001 | |||
7 | X00001 | 255666 | 13 | ZV0001 | |||
8 | C5678 | 103000 | 90 | ZV0002 | |||
9 | X00002 | 145444 | 17 | ZV0002 | |||
10 | X00002 | 173000 | 19 | ZV0002 | |||
11 | X00002 | 199000 | 27 | ZV0002 | |||
12 | X00002 | 212000 | 16 | ZV0002 | |||
13 | X00002 | 255666 | 11 | ZV0002 | end | ||
14 | C5678 | 103000 | 80 | ZV0003 | |||
15 | X00003 | 145444 | 15 | ZV0003 | |||
16 | X00003 | 173000 | 10 | ZV0003 | |||
17 | X00003 | 199000 | 32 | ZV0003 | |||
18 | X00003 | 212000 | 14 | ZV0003 | |||
19 | X00003 | 255666 | 9 | ZV0003 | |||
20 | C5678 | 103000 | 70 | ZV0004 | |||
21 | X00004 | 145444 | 13 | ZV0004 | |||
22 | X00004 | 173000 | 27 | ZV0004 | |||
23 | X00004 | 199000 | 10 | ZV0004 | |||
24 | X00004 | 212000 | 12 | ZV0004 | |||
25 | X00004 | 255666 | 8 | ZV0004 | end | ||
26 | C5678 | 103000 | 60 | ZV0005 | |||
27 | X00005 | 145444 | 11 | ZV0005 | |||
28 | X00005 | 173000 | 21 | ZV0005 | |||
29 | X00005 | 199000 | 10 | ZV0005 | |||
30 | X00005 | 212000 | 10 | ZV0005 | |||
31 | X00005 | 255666 | 8 | ZV0005 | |||
Sheet2 |
This is just a small sample to illustrate what I am trying to achieve.
I have thousands of rows of data on one sheet. I need to split this data out based on whether the word "end" appears in column E. So in the above, A2:A13 would be copied to a new worksheet.
Then A14:A25 would be copied to a new sheet.
And so on. So the flow would be (i) identify first range to be copied, (ii) add a new worksheet, (iii) paste the data.
Any pointers appreciated.