I wish to create a simple macro which will update a range of cells D4:K32.
These cells use a VLookup function to find data in another workbook.
Basically, I want to refresh their numbers since each day, the source workbook may change.
I do not want to have to open to source workbook.
Currently I have this code. Note, the workbook I'm updating cells for is called "Estimates" and the source workbook I have name "file" and is in the directory O:\E\K.
Sub Refresh_Well_Tests()
ChDir "O:\E\K"
Workbooks.Open FileName:= _
"O:\E\K\file.xls" _
, UpdateLinks:=0
Windows("Estimates.xls").Activate
Range("D4:K32").Select
Calculate
Range("A19").Select
End Sub
This pretty much opens the workbook then presses "Enter" on each cell in Estimates to refresh them.
Is there a better way to do this?
Refresh links?
Using special code which does the same action without the source workbook opening?
Thanks!
Bookmarks