Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have tried to create a macro that will copy and paste information between
two woorkbooks. One of these always has the same file name (and is a read only template) where as the other will vary as it is used by different individuals. Can this be done? Regards Jorge |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Try something like
Workbooks("Book5.xls").Worksheets("SHeet1").Range( "A1:A5").Copy _ Destination:=Workbooks("Book6.xls").Worksheets("Sh eet1").Range("A1") -- Cordially, Chip Pearson Microsoft MVP - Excel Pearson Software Consulting, LLC www.cpearson.com "Jorge" wrote in message ... I have tried to create a macro that will copy and paste information between two woorkbooks. One of these always has the same file name (and is a read only template) where as the other will vary as it is used by different individuals. Can this be done? Regards Jorge |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thanks Chip,
But as I'm not a programmer I'm not sure if I was able to take advantage of your advice. Would you posibly be able to be a little more exlplicit in my case. It didn't seem to help. In any case whatever I name the variable file there is no way I can control what others will name theirs. The file is actually a work time sheet so the file name will contain a date, which as you can imagine changes regularly. Regards Jorge "Chip Pearson" wrote: Try something like Workbooks("Book5.xls").Worksheets("SHeet1").Range( "A1:A5").Copy _ Destination:=Workbooks("Book6.xls").Worksheets("Sh eet1").Range("A1") -- Cordially, Chip Pearson Microsoft MVP - Excel Pearson Software Consulting, LLC www.cpearson.com "Jorge" wrote in message ... I have tried to create a macro that will copy and paste information between two woorkbooks. One of these always has the same file name (and is a read only template) where as the other will vary as it is used by different individuals. Can this be done? Regards Jorge |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
cant you put the code in the file which the date changes and get it to open
and extract the data from the one that is always nammed the same "Jorge" wrote: Thanks Chip, But as I'm not a programmer I'm not sure if I was able to take advantage of your advice. Would you posibly be able to be a little more exlplicit in my case. It didn't seem to help. In any case whatever I name the variable file there is no way I can control what others will name theirs. The file is actually a work time sheet so the file name will contain a date, which as you can imagine changes regularly. Regards Jorge "Chip Pearson" wrote: Try something like Workbooks("Book5.xls").Worksheets("SHeet1").Range( "A1:A5").Copy _ Destination:=Workbooks("Book6.xls").Worksheets("Sh eet1").Range("A1") -- Cordially, Chip Pearson Microsoft MVP - Excel Pearson Software Consulting, LLC www.cpearson.com "Jorge" wrote in message ... I have tried to create a macro that will copy and paste information between two woorkbooks. One of these always has the same file name (and is a read only template) where as the other will vary as it is used by different individuals. Can this be done? Regards Jorge |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Rich,
It doesn't work that way. The reason being that firstly it's protected worksheet with only specific cells unprotected. Secondly, as the macro needs to refer back to the variable workbook to copy information, once the filename changes the macro is no longer viable. This is the hurdle, if at all possible, I'm trying to overcome. Regards Jorge "Rich Mcc" wrote: cant you put the code in the file which the date changes and get it to open and extract the data from the one that is always nammed the same "Jorge" wrote: Thanks Chip, But as I'm not a programmer I'm not sure if I was able to take advantage of your advice. Would you posibly be able to be a little more exlplicit in my case. It didn't seem to help. In any case whatever I name the variable file there is no way I can control what others will name theirs. The file is actually a work time sheet so the file name will contain a date, which as you can imagine changes regularly. Regards Jorge "Chip Pearson" wrote: Try something like Workbooks("Book5.xls").Worksheets("SHeet1").Range( "A1:A5").Copy _ Destination:=Workbooks("Book6.xls").Worksheets("Sh eet1").Range("A1") -- Cordially, Chip Pearson Microsoft MVP - Excel Pearson Software Consulting, LLC www.cpearson.com "Jorge" wrote in message ... I have tried to create a macro that will copy and paste information between two woorkbooks. One of these always has the same file name (and is a read only template) where as the other will vary as it is used by different individuals. Can this be done? Regards Jorge |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
2 windows for workbook - Macro switches worksheet | Excel Discussion (Misc queries) | |||
Macros with switches | Excel Programming | |||
Don't show sheet switches when running macro | Excel Programming | |||
Macro for Filter Switches ... Maybe??? | Excel Discussion (Misc queries) | |||
Filter Switches vs Macro? | Excel Discussion (Misc queries) |