ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Copying records to another worksheet (https://www.excelbanter.com/excel-programming/415168-copying-records-another-worksheet.html)

marcia2026

Copying records to another worksheet
 
I am currently using Ron de Bruin's macro that copies unique values to
separate sheets. Currently, they copy into the same workbook. I would like
for them to copy into separate workbooks. I have tried his other macro for
copying to separate workbooks, but it creates a new workbook each time you
run the macro.

I have 3 unique values in the control sheet. The control workbook has
numerous worksheets because a new one is created for each working day of the
month. With your help I have been able to specify which sheet is being
copied and how to give the new sheets a unique name, but I would really like
for those sheets to in copy into specific folders set up in the master folder.

Master folder would have these four workbooks: Control, MV, RMS, BE.



marcia2026

Copying records to another worksheet
 
What is wrong with these statements?

Sheets.("RMS" & " " & ws1.Name).Select
Sheets("RMS" & " " & ws1.Name).Move
Befo=Workbooks("RMS.xls").Sheets(blank) <<< it bugged out here


Sheets("MV" & " " & ws1.Name).Select
Sheets("MV" & " " & ws1.Name).Move
Befo=Workbooks("MV.xls").Sheets(blank)

I recorded a macro moving these sheets to another workbook, and pasted it in
at the end of the macro.


"marcia2026" wrote:

I am currently using Ron de Bruin's macro that copies unique values to
separate sheets. Currently, they copy into the same workbook. I would like
for them to copy into separate workbooks. I have tried his other macro for
copying to separate workbooks, but it creates a new workbook each time you
run the macro.

I have 3 unique values in the control sheet. The control workbook has
numerous worksheets because a new one is created for each working day of the
month. With your help I have been able to specify which sheet is being
copied and how to give the new sheets a unique name, but I would really like
for those sheets to in copy into specific folders set up in the master folder.

Master folder would have these four workbooks: Control, MV, RMS, BE.




All times are GMT +1. The time now is 07:19 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com