Embed or import one excel workbook to other vba

Posted on 2016-09-24
Medium Priority
Last Modified: 2016-09-25
I have a multiple workbooks which has columns to Workbook and I have standard a standard excel file. All i have to copy each workbook into standard template and save the template with cell D1 and re56yrsasz z  s,m`nbx   xsnww212 3peat the processes for all workbooks

Process in detail:

Say I have workbooks as 1.xslx; 2.xlsx; 3.xslx; etc., in a particular folder

and i have standard Excel template (Xlsm)

data from (specific columns) each workbook gets copied to excel template and save the template as cell d1 of workbook

how do I create a vba to do this?

I have found some help here but how can read all the excel workbooks?


hope I am clear
Question by:Nirvana
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 4
LVL 21

Expert Comment

by:Roy Cox
ID: 41813809
Attach an example of the source workbooks and the master workbook
LVL 21

Accepted Solution

Roy Cox earned 2000 total points
ID: 41814412
Try this

The Output files should be in a subfolder named "Data" within the folder that the Input file is stored in.

The code will open each workbook in that subfolder & import the data
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!


Author Comment

ID: 41814427
Hi Roy, nothing seems to happening when i click on import. I have multiple workbooks in the source folder and i have created a folder with "data" and an excel file. when i click on it.. nothing is happening. this query is linked to the previous question i have asked. as I was able to create multiple workbooks I am posting this question

LVL 21

Expert Comment

by:Roy Cox
ID: 41814438
The code works perfectly on the sample files.  Reading the other question is that creating files for each name in the workbook?

I'm going out for an hour or so but I'll check when I get back.

I think I need to work on your previous question first.

Author Comment

ID: 41814444
Sure Roy.. thanks a ton!! for all your help. please bear in mind..output is an upload template to oracle and the data needs to be pasted from row10. again thanks a lot. appreciate it a ton!!!
LVL 21

Expert Comment

by:Roy Cox
ID: 41814712
I have  answered your previous question.

This code works for me here, but I think it is unnecessary now that my other code produces the files. Let me know if you need any more help.

Author Closing Comment

ID: 41815086
Simply great
LVL 21

Expert Comment

by:Roy Cox
ID: 41815382
Pleased to help

Featured Post


Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Excel can be a tricky bit of software to get your head around. Whilst you’ll be able to eventually get to grips with the basic understanding of how to get by, there are a few Excel tips that not everybody will even know about let alone know how to d…
You need to know the location of the Office templates folder, so that when you create new templates, they are saved to that location, and thus are available for selection when creating new documents.  The steps to find the Templates folder path are …
This Micro Tutorial demonstrates how to create Excel charts: column, area, line, bar, and scatter charts. Formatting tips are provided as well.
This Micro Tutorial will demonstrate in Google Sheets how to use the HYPERLINK function to create live links inside your spreadsheet.

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question