Shweta
Well-known Member
- Joined
- Jun 5, 2011
- Messages
- 514
Hi All,
I have 31 files in a folder naming such as "20111002 Daily Performance",
"20111003 Daily Performance", "20111004 Daily Performance" and so on.
Now I need to copy all the files in a single workbook on sheet1 and I am able to do it with the help of a macro but the problem is I don't need to copy the files containing data for saturday and sunday. that means I only want to copy the files for working days that is monday to friday. ( I think weekday can be calculated by the date in the filename)
Need a macro for this.
Second problem is after copying a single file I need to insert a column at the beginning of the data where I want to enter the date ( date should be same as the date in filename)
for example : - I want to copy "20111002" from the file name "20111002 Daily Performance" after copying the data from this file. It should be in mm/dd/yyyy format.
STEP 1: - copy the data from a file into a single workbook ( this is for reference, don't need help on this)
STEP 2: - after copying the data want to insert a column at the beginning of the data as column A ( want help on this)
STEP 3: - In column A(that we have inserted in step 2) want date from the file name in mm/dd/yyyy format
Note: - Don't want to copy the data for saturday and sunday.
This is a very critical task for me. I tried a lot but unable to perform the complete task.Need your help!
Thanks in advance!
Regards,
Shweta
I have 31 files in a folder naming such as "20111002 Daily Performance",
"20111003 Daily Performance", "20111004 Daily Performance" and so on.
Now I need to copy all the files in a single workbook on sheet1 and I am able to do it with the help of a macro but the problem is I don't need to copy the files containing data for saturday and sunday. that means I only want to copy the files for working days that is monday to friday. ( I think weekday can be calculated by the date in the filename)
Need a macro for this.
Second problem is after copying a single file I need to insert a column at the beginning of the data where I want to enter the date ( date should be same as the date in filename)
for example : - I want to copy "20111002" from the file name "20111002 Daily Performance" after copying the data from this file. It should be in mm/dd/yyyy format.
STEP 1: - copy the data from a file into a single workbook ( this is for reference, don't need help on this)
STEP 2: - after copying the data want to insert a column at the beginning of the data as column A ( want help on this)
STEP 3: - In column A(that we have inserted in step 2) want date from the file name in mm/dd/yyyy format
Note: - Don't want to copy the data for saturday and sunday.
This is a very critical task for me. I tried a lot but unable to perform the complete task.Need your help!
Thanks in advance!
Regards,
Shweta
Last edited: