Hi all
I have folder with a lot files like: xxxxxx-yyyyyyyy-zzzzzzzz-wwwww-aa-b-cc with extension: .xlsx .xlx .rpt .doc .docx
Please help me with macro VBA to do that:
1. Brown to folder and get all files full name include extension: .xlsx .xlx .rpt to sheets("data") begin from range ("A2")
2. Split all file name from column(A) to column B,C,D,E,F,G,H,I for each dash "-"
The result like this, I examble 03 row but realyty rows defend on the file name in folder from 200 to 500 files each month:
[TABLE="class: grid, width: 500"]
<tbody>[TR]
[TD][/TD]
[TD]A[/TD]
[TD]B[/TD]
[TD]C[/TD]
[TD]D[/TD]
[TD]E[/TD]
[TD]F[/TD]
[TD]G[/TD]
[TD]H[/TD]
[TD]I[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]xxxxx-yyyyyyyy-zzzzzzzz-wwwww-aa-b-cc.xlsx[/TD]
[TD]xxxxxx[/TD]
[TD]yyyyyyyy[/TD]
[TD]zzzzzzzz[/TD]
[TD]wwwwww[/TD]
[TD]aa[/TD]
[TD]b[/TD]
[TD]cc[/TD]
[TD]xlsx[/TD]
[/TR]
[TR]
[TD]2[/TD]
[TD]xxxxxx-yyyyyyyy-zzzzzzzz-wwwww-aa-b-cc.xls[/TD]
[TD]xxxxxx[/TD]
[TD]yyyyyyyy[/TD]
[TD]zzzzzzzz[/TD]
[TD]wwwwww[/TD]
[TD]aa[/TD]
[TD]b[/TD]
[TD]cc[/TD]
[TD]xls[/TD]
[/TR]
[TR]
[TD]3[/TD]
[TD]xxxxxx-yyyyyyyy-zzzzzzzz-wwwww-aa-b-cc.rpt[/TD]
[TD]xxxxxx[/TD]
[TD]yyyyyyyy[/TD]
[TD]zzzzzzzz[/TD]
[TD]wwwwww[/TD]
[TD]aa[/TD]
[TD]b[/TD]
[TD]cc[/TD]
[TD]rpt[/TD]
[/TR]
</tbody>[/TABLE]
Thanks in advance.
I have folder with a lot files like: xxxxxx-yyyyyyyy-zzzzzzzz-wwwww-aa-b-cc with extension: .xlsx .xlx .rpt .doc .docx
Please help me with macro VBA to do that:
1. Brown to folder and get all files full name include extension: .xlsx .xlx .rpt to sheets("data") begin from range ("A2")
2. Split all file name from column(A) to column B,C,D,E,F,G,H,I for each dash "-"
The result like this, I examble 03 row but realyty rows defend on the file name in folder from 200 to 500 files each month:
[TABLE="class: grid, width: 500"]
<tbody>[TR]
[TD][/TD]
[TD]A[/TD]
[TD]B[/TD]
[TD]C[/TD]
[TD]D[/TD]
[TD]E[/TD]
[TD]F[/TD]
[TD]G[/TD]
[TD]H[/TD]
[TD]I[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]xxxxx-yyyyyyyy-zzzzzzzz-wwwww-aa-b-cc.xlsx[/TD]
[TD]xxxxxx[/TD]
[TD]yyyyyyyy[/TD]
[TD]zzzzzzzz[/TD]
[TD]wwwwww[/TD]
[TD]aa[/TD]
[TD]b[/TD]
[TD]cc[/TD]
[TD]xlsx[/TD]
[/TR]
[TR]
[TD]2[/TD]
[TD]xxxxxx-yyyyyyyy-zzzzzzzz-wwwww-aa-b-cc.xls[/TD]
[TD]xxxxxx[/TD]
[TD]yyyyyyyy[/TD]
[TD]zzzzzzzz[/TD]
[TD]wwwwww[/TD]
[TD]aa[/TD]
[TD]b[/TD]
[TD]cc[/TD]
[TD]xls[/TD]
[/TR]
[TR]
[TD]3[/TD]
[TD]xxxxxx-yyyyyyyy-zzzzzzzz-wwwww-aa-b-cc.rpt[/TD]
[TD]xxxxxx[/TD]
[TD]yyyyyyyy[/TD]
[TD]zzzzzzzz[/TD]
[TD]wwwwww[/TD]
[TD]aa[/TD]
[TD]b[/TD]
[TD]cc[/TD]
[TD]rpt[/TD]
[/TR]
</tbody>[/TABLE]
Thanks in advance.