MATLAB: Does MATLAB 7.4 (R2007a) no longer prompt me to update the Excel cells when using XLSREAD

MATLAB

I use XLSREAD on an Excel file with formulae and links. Older versions of MATLAB used to prompt me whether I want to update the cells in my file. MATLAB 7.4 (R2007a) does not.
In R2007a, the side effect of this is that Excel automatically tries to update the links and some columns then contain #N/A – even the valid data in these columns is not read in.

Best Answer

The ability to choose whether to update the cells when using XLSREAD is not available in MATLAB 7.4 (R2007a).
To work around this in MATLAB 7.4 (R2007a):
1. Go to $MATLABROOT\toolbox\matlab\iofun\
2. Create a copy of the xlsread.m file and name the copy to xlsread.m.old
3. Open xlsread.m in MATLAB using the command:
edit xlsread
4. On line 261, change:
Excel.AskToUpdateLinks = 0;
to
Excel.AskToUpdateLinks = 1;
5. Run: rehash toolboxcache
This should re-enable the prompt to update the cells.