Hello, I am using the typical cell links between some of my workbooks to retrieve data. The odd thing is that some of these links are not updating at all. My main WB is getting its data from two different source workbooks (which have multiple worksheets in them) and the data from one of the source workbooks all transfer fine, but the second source workbook is hit and miss - sometimes it will or sometimes it won't. I am using the code below to update the main workbook every 30 minutes, and it seems to work fine with the exception of the issues as noted. If I have all of the WB's open on my desktop everything updates correctly. And If I close them out and open the WB's on the servers I see that the links also update with the server name as it is supposed to. So everything looks like it normally does.
The only thing different that I can see between the two source workbooks is that the first source workbooks data is all coming from the same worksheet, whereas in the second source workbook I am getting data from a couple of worksheets. My understand has always been that all I had to do update my data was to open the workbook(s), not necessarily to activate each of the sheets. Is that correct? I am wondering if I need to open the WB's and then cycle through the worksheets in order to get the data to update.
I appreciate any insights - thanks
The only thing different that I can see between the two source workbooks is that the first source workbooks data is all coming from the same worksheet, whereas in the second source workbook I am getting data from a couple of worksheets. My understand has always been that all I had to do update my data was to open the workbook(s), not necessarily to activate each of the sheets. Is that correct? I am wondering if I need to open the WB's and then cycle through the worksheets in order to get the data to update.
I appreciate any insights - thanks
VBA Code:
Sub UpdateLinks()
ActiveWorkbook.UpdateLink Name:="L:\CommonRW\FacilitiesApps.xlsm", Type:= _
xlExcelLinks
ActiveWorkbook.UpdateLink Name:= _
"L:\CommonRW\Facilities Inspection App.xlsm", Type:= _
xlExcelLinks
Application.OnTime DateAdd("s", 1800, Now), "UpdateLinks"
[B99] = Now
With ActiveSheet.Shapes("Rectangle 13").Fill
.Visible = msoTrue
.UserPicture "L:\CommonRW\Facilities Information Center\FacCal.gif"
.TextureTile = msoFalse
End With
ActiveWorkbook.Save
End Sub