-1

Hope all are doing great. Bit new to VBA so I need your help to create code for below situation.

I have an excel where at

F4 - i have a folder path which contains excel files

In F5 i have one excel file name contain in F4 path

  • Sample No Match 20200728.xlsx

In F6, i have one more excel file name contain in f4 path

  • Sample Yes Match 20200728.xlsx

Now i want my macro to -

  1. Go to F4 Path
  2. Create New Workbook by name of "Consolidated Sample Today"
  3. Copy and paste the data of file in F5 into new workbook
  4. Copy and paste the data of file.in F6 after the data of F5 ( Below of that as it has same header)
  5. Save and close all workbook in F4 path

Please let me.know.if you need any further information on the same. Your response will.be appreciated

Note - I have to pick file.name from excel only

Pᴇʜ
  • 56,719
  • 10
  • 49
  • 73

1 Answers1

0

You can find many answers here for sure! But as for Microsoft stuff, their documentation is pretty good, too. For example, here's How to create a workbook in VBA

As for copying a workbook to another workbook, this should get you going How to copy sheets to another workbook using VBA

Joe Beck
  • 401
  • 2
  • 13