Import multiple data sources into worksheet

mabbott

New Member
Joined
Jul 22, 2010
Messages
4
Hi all,

I currently have a workbook which consists of a worksheet for each financial week of the year to which I manually copy daily volume and vehicle capcities into according to which week they refer to. After the data is copied over I am then adding VLOOKUP and other formuals to analyze this data

I would like to create a marco that automatically imports the data and formats it according to my needs and also adding the formulas that I'm using.

The data that I wish to import gets sent to me as an .xls file and is named according to the day it covers for example "9418GR - OTOLQL - Shipment Volume - Mon-12-Jul-10.xls".

My questions more refers to actually the import process as the file name changed daily...can this be written into the marco? Also how do I specify which worksheet the data gets copied to.

Thanks for all help in advance!!
 

Some videos you may like

Excel Facts

Do you hate GETPIVOTDATA?
Prevent GETPIVOTDATA. Select inside a PivotTable. In the Analyze tab of the ribbon, open the dropown next to Options and turn it off

John Davis

Well-known Member
Joined
Sep 11, 2007
Messages
3,457
Hi all,

I currently have a workbook which consists of a worksheet for each financial week of the year to which I manually copy daily volume and vehicle capcities into according to which week they refer to. After the data is copied over I am then adding VLOOKUP and other formuals to analyze this data

I would like to create a marco that automatically imports the data and formats it according to my needs and also adding the formulas that I'm using.

The data that I wish to import gets sent to me as an .xls file and is named according to the day it covers for example "9418GR - OTOLQL - Shipment Volume - Mon-12-Jul-10.xls".

My questions more refers to actually the import process as the file name changed daily...can this be written into the marco? Also how do I specify which worksheet the data gets copied to.

Thanks for all help in advance!!

You could probably use something like this to capture the changing days.


Workbooks.Open Filename:="D:\Common\data\excel\9418GR-OTOLQL-Shipment Volume- " & Format(DateAdd("d", 0, Date), "ddd-dd-mmm-yy") & ".xls"

And you could use the macro recorder to record a session for placing your formulas and vlookups. At least that would get you started.
 

Subscribe on YouTube

Watch MrExcel Video

Forum statistics

Threads
1,106,606
Messages
5,512,392
Members
408,889
Latest member
2vbr

This Week's Hot Topics

  • Sort code advice please
    Hi, I have the code below which im trying to edit but getting a little stuck. This was the original code which worked fine,columns A-F would sort...
  • SUMPRODUCT with nested If statement
    Hi everyone, Hope you're all well. I'm hoping someone will be able to point me in the right direction with a problem I'm having with a SUMPRODUCT...
  • VBA - simple sort is killing me!
    Hello all! This should be so easy, but not for me, apparently! I have a table of data that can be of varying lengths and widths. My current macro...
  • Compare Two Lists
    I have two Lists and I need to be able to Identify differences between them. List 100 comes from a workbook - the other is downloaded form the...
  • Formula that deducts points for each code I input.
    I am trying to create a formula that will have each student in my class start at 100 points and then for each code that I enter (PP for Poor...
  • Conditional formatting formula required for day of week and a value
    Hi, I have a really simple spreadsheet where column A is the date, column B is the activity total shown as a number and column C states the day of...
Top