ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Macro-copy (https://www.excelbanter.com/excel-discussion-misc-queries/242934-re-macro-copy.html)

puiuluipui

Macro-copy
 
Hi Luke... this workbook(with date name) will be open.
I don't want to open from folder because in this folder i will store all
workbooks (01.09.2009;02.09.2009;03.09.2009.....), so it will be dificult i
guess, that the macro to pick the last date. So, i want to copy from open
workbook with date as name.
Can this be done?
Thanks!


"Luke M" a scris:

Perhaps something like this?

MyWorkBook = "was" & Format(Date, "dd.mm.yyyy")

Workbooks.Open Filename:= _
"C:\Documents and Settings\My Documents\" & MyWorkBook & ".xls"

--
Best Regards,

Luke M
*Remember to click "yes" if this post helped you!*


"puiuluipui" wrote:

Hi, i need to copy a range from another workbook, but the name of the
workbook is different each day, so i need to copy from a workbook that is
named as dates (Today) yesterday workbook's name was16.09.2009. today
workbook's name is 17.09.2009. I don't want to change macro, so i need to
copy from a workbook with name as Date (Today's date)

Can this be done?
Thanks!



All times are GMT +1. The time now is 02:43 AM.

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