Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
D.R. - Help
 
Posts: n/a
Default 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   Report Post  
DougT
 
Posts: n/a
Default

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   Report Post  
Duke Carey
 
Posts: n/a
Default

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
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
fixed string length,even other record is copied viv Excel Discussion (Misc queries) 0 May 30th 05 08:28 PM
Excel Object copied to Word not printing in color dmotika Excel Discussion (Misc queries) 0 May 26th 05 04:40 PM
Sorting referenced cells jcouncill New Users to Excel 2 December 21st 04 07:32 PM
Copy/insert copied cells when protection is on... BeSmart Excel Worksheet Functions 1 December 15th 04 01:48 AM
Named dynamic ranges, copied worksheets and graph source data WP Charts and Charting in Excel 1 November 28th 04 05:19 PM


All times are GMT +1. The time now is 06:07 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"