Home |
Search |
Today's Posts |
#1
|
|||
|
|||
can it be copied instead of referenced
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. |
#2
|
|||
|
|||
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 |
#3
|
|||
|
|||
Simplify to
range("A1:F136").Value = Workbooks("doc2.xls").Sheets(1).range("A1:F136").V alue "DougT" wrote: 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 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
fixed string length,even other record is copied | Excel Discussion (Misc queries) | |||
Excel Object copied to Word not printing in color | Excel Discussion (Misc queries) | |||
Sorting referenced cells | New Users to Excel | |||
Copy/insert copied cells when protection is on... | Excel Worksheet Functions | |||
Named dynamic ranges, copied worksheets and graph source data | Charts and Charting in Excel |