0

I need to copy specific sheets from a workbook to another workbook. i used below codes but not working.

    Sub copy_fromwb()

    Workbooks("LLT RM Sep'19.xlsm").Sheets("R5903078-Sep'19").Copy _
        after:=Workbooks("LLT RM Oct'19.xlsm").Sheets("R5903078-Aug'19")

    End Sub

Run time error

Teamothy
  • 2,000
  • 3
  • 16
  • 26
  • 1
    See [here](https://stackoverflow.com/questions/6863940/how-to-copy-sheets-to-another-workbook-using-vba/6865661) – Dean Oct 03 '19 at 08:09
  • The command syntax is fine. However, you have 4 references in that and all of them can fail. Why don't you split the command like `Set wb = Workbooks("LLT RM Sep'19.xlsm")` then `Set sh = wb.Sheets("R5903078-Sep'19")`, etc, and then run it step by step to see wich command fails. – AcsErno Oct 03 '19 at 08:39
  • Possible duplicate of [How to copy sheets to another workbook using vba?](https://stackoverflow.com/questions/6863940/how-to-copy-sheets-to-another-workbook-using-vba) – Miles Fett Oct 03 '19 at 13:26

0 Answers0