ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Opening Workbooks (https://www.excelbanter.com/excel-programming/387090-opening-workbooks.html)

Brent

Opening Workbooks
 
I am coding using VBA and ADO. Trying to make an automated system that goes
to a folder and opens a file, loads the data needed, and closes the file, one
after the other for all the files in the folder. I want to do this without
referencing the names of any of the workbooks because the names change daily.
Is there any way to do this?? Thank you.

Brent

Ron de Bruin

Opening Workbooks
 
Hi Brent

See this page
http://www.rondebruin.nl/copy3.htm

--

Regards Ron de Bruin
http://www.rondebruin.nl/tips.htm


"Brent" wrote in message ...
I am coding using VBA and ADO. Trying to make an automated system that goes
to a folder and opens a file, loads the data needed, and closes the file, one
after the other for all the files in the folder. I want to do this without
referencing the names of any of the workbooks because the names change daily.
Is there any way to do this?? Thank you.

Brent


Brent

Opening Workbooks
 
It looks like I would have to enter the names manually into a sheet in the
workbook. I do not want to worry about the names at all, but I still want
the program to go through each file. Thank you.



"Ron de Bruin" wrote:

Hi Brent

See this page
http://www.rondebruin.nl/copy3.htm

--

Regards Ron de Bruin
http://www.rondebruin.nl/tips.htm


"Brent" wrote in message ...
I am coding using VBA and ADO. Trying to make an automated system that goes
to a folder and opens a file, loads the data needed, and closes the file, one
after the other for all the files in the folder. I want to do this without
referencing the names of any of the workbooks because the names change daily.
Is there any way to do this?? Thank you.

Brent



Ron de Bruin

Opening Workbooks
 
If all workbooks are in a folder you can run the code for all workbooks without knowing the names
There is also a macro to select the files

--

Regards Ron de Bruin
http://www.rondebruin.nl/tips.htm


"Brent" wrote in message ...
It looks like I would have to enter the names manually into a sheet in the
workbook. I do not want to worry about the names at all, but I still want
the program to go through each file. Thank you.



"Ron de Bruin" wrote:

Hi Brent

See this page
http://www.rondebruin.nl/copy3.htm

--

Regards Ron de Bruin
http://www.rondebruin.nl/tips.htm


"Brent" wrote in message ...
I am coding using VBA and ADO. Trying to make an automated system that goes
to a folder and opens a file, loads the data needed, and closes the file, one
after the other for all the files in the folder. I want to do this without
referencing the names of any of the workbooks because the names change daily.
Is there any way to do this?? Thank you.

Brent



Brent

Opening Workbooks
 
Thank you. That helped.

Brent


"Ron de Bruin" wrote:

If all workbooks are in a folder you can run the code for all workbooks without knowing the names
There is also a macro to select the files

--

Regards Ron de Bruin
http://www.rondebruin.nl/tips.htm


"Brent" wrote in message ...
It looks like I would have to enter the names manually into a sheet in the
workbook. I do not want to worry about the names at all, but I still want
the program to go through each file. Thank you.



"Ron de Bruin" wrote:

Hi Brent

See this page
http://www.rondebruin.nl/copy3.htm

--

Regards Ron de Bruin
http://www.rondebruin.nl/tips.htm


"Brent" wrote in message ...
I am coding using VBA and ADO. Trying to make an automated system that goes
to a folder and opens a file, loads the data needed, and closes the file, one
after the other for all the files in the folder. I want to do this without
referencing the names of any of the workbooks because the names change daily.
Is there any way to do this?? Thank you.

Brent




All times are GMT +1. The time now is 06:05 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com