can it be copied instead of referenced

D

D.R. - Help

Hello --

i'm working on a spreadsheet form (doc 1) that looks at another spreadsheet
(doc 2 for 07/11/05, doc 2 for 07/12/05, doc 2 for 07/13/05 etc)) to grab
values on specific cells and displays them in the spreadsheet form (doc1).
However, doc 1 is dependant on doc 2 so if i close it the values are no
longer displayed. Since doc 2 will change on a daily basis, is there any way
or function i can use that will reference the cells i need but permanently
copy these values so doc 1 is not dependent on doc 2 but once the values are
referenced for that day it is available permanently. Thank you so much.
 
D

DougT

You would have to use macro VBA code similar to this:

Sub Macro1()
Windows("doc2_filename").Activate
Sheets("sheet1").Range("A1:F136").Copy
Windows("doc1_filename").Activate
Sheets("sheet1").Range("a1").PasteSpecial Paste:=xlPasteValues
Sheets("sheet1").Range("a1").PasteSpecial Paste:=xlPasteFormats
Range("A1").Select
End Sub
 
D

Duke Carey

Simplify to

range("A1:F136").Value =
Workbooks("doc2.xls").Sheets(1).range("A1:F136").Value
 
Top