LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
 
Posts: n/a
Default Updating master workbook from source that may/may not exist

I am using Excel 2003 and have a master workbook that has many
references (links) to various other workbooks that are in Excel 4.0
format. These source files are created from a query each month.
Depending on the time of the year the source workbook may not exist
yet. I wrote a function (fileexists) in VBA that checks for the
exisatence of the source file. If it exists the function returns true
and then the I use the link to pull in the value to the master
workbook. If it doesn't exist I put a space in the cell instead. Here's
an example from a cell in the master workbook:

=IF(fileexists("managerstmtmo01.xls"),'[managerstmtmo01.xls]managerstmtmo01'!$D$10,"
")

This all works great except I've noticed one problem. If the cell in my
master workbook was once updated because the source file existed, but
then I've renamed or deleted the source file, the value it originally
pulled in from the source file remains in the master workbook's cell.
The only way I can remove the previous value is to edit each cell's
function. When I do that Excel tries to update the link value and I
cancel that, then the cell is blank. Is there a way to have Excel
recalculate each cell and put a space in the cell if the source file
doesn't exist? When I open the master workbook I have it Update the
links then it tells me there are links that can't be updated (because
the source file doesn't exist). Regardless of either telling Excel to
continue or edit the links and not update them, the same thing happens.
The cells in the master workbook are not changed. I've also set Update
Remote References to yes and Save External Link Values to no on the
Calculations tab of Options. Can I do what I'm trying to do or is there
another way to accomplish this?

Thanks.

 
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
Multiple workbook user's with Master workbook - all password protected Yvon Excel Discussion (Misc queries) 2 March 30th 05 01:34 PM
Master Workbook used as my template? tb New Users to Excel 4 March 10th 05 11:42 PM
Winn98SE, Excel2000: ODBC query opens the source workbook Arvi Laanemets Excel Discussion (Misc queries) 9 March 10th 05 06:32 AM
Updating multiple worksheets in a large workbook Graham Excel Discussion (Misc queries) 3 February 11th 05 10:29 AM
XL2003 Destination and Source Open but not updating tim Excel Discussion (Misc queries) 2 December 14th 04 01:29 AM


All times are GMT +1. The time now is 11:23 PM.

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

About Us

"It's about Microsoft Excel"