LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 138
Default Querying an Excel File with a changing file name

I need to pull data from a daily generated excel file, with a changing
file name. The file will always be in the same location.

I ran the connection info on the excel file I would like to hit (tip --
see this useful thread he

http://groups.google.ca/group/comp.d...c993a4/?hl=en#
or tips on gathering the connection information and SQL from a broken
query) and it came back with this:

ODBC;DSN=Excel Files;DBQ=C:\ExcelFiles\ExcelFile - Mar. 2,
07.xls;DefaultDir=C:\ExcelFiles
\;DriverId=790;MaxBufferSize=2048;PageTimeout=5;

What I want to do is refresh a query with a piece of VBA so that it
will always pull in the ExcelFile of the current date [ie "Excelfile -
" & format(date, "Mmm. dd, yy") & ".xls" ]

Can anyone help with that?

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
delete info from source file w/out changing the destination file TB New Users to Excel 0 May 26th 08 06:26 PM
Open Test file with VBA with a changing file number Michael from Austin Excel Programming 4 October 14th 05 03:18 PM
Querying a CSV file from Excel ExcelMonkey[_115_] Excel Programming 2 May 11th 04 10:31 AM
Importing/querying data from .mdb file into Excel jimmy shaker. Excel Programming 5 January 11th 04 03:38 PM
Open delimited text file to excel without changing data in that file zohanc Excel Programming 1 October 3rd 03 01:06 AM


All times are GMT +1. The time now is 09:16 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"