I am trying to write some lines to get the certian cell
AAA value from an excel file by changing other values of
certain cell BBB in the same Excel. The problem is that it
seems the Excel will not save my change and do the
calcualtion and thus the value at cell BBB is that
corresponds to old values in cell AAA.
This is an interactice process. Following
is what I have so far:
for isec = 1:2
xlswrite(filename,V_sec(isec),'DesignValues','O61')
for iface=1:1
xlswrite(filename,V_fac
(iface),'DesignValues','R61')
[Numeric,x1,x2]=xlsread
(filename,'DesignValues','E66:K66');
Numeric
xlswrite('aa',Numeric,'DesignValues','a1:g1')
end
end
The values in CELL 'O61' & 'R61' of SHEET-'DesignValues'
will be changed in every loop. Correspondingly, the cell
values in CELL 'a1:g1' of SHEET 'DesignValues' are
expected to change by Excel's autocalculation.
Here is the problem: the output values in "Numeric" are
all the same for each loop run. Seems the Excel did not
actually update the values at CELL 'O61' & 'R61' and do
the calculation.
Can anyone tell me what is the problem and how to fixed
it. Is there any command like SAVE in MATLAB to make the
excel to SAVE the changes I made ?
This was posted before. Sorry for asking the questions
again
Thanks.
Stuart McGarrity - 23 Jul 2008 20:19 GMT
"Bruce Heu" <yuanxin1999@hotmail.com> wrote in message
<g67mc6$agb$1@fred.mathworks.com>...
> I am trying to write some lines to get the certian cell
> AAA value from an excel file by changing other values of
[quoted text clipped - 38 lines]
>
> Thanks.
I think you should consider using COM(activeX) commands if
you are doing something as complicated as this. You can tell
Excel to do anything you want. See Excel example on this page:
http://www.mathworks.com/access/helpdesk/help/techdoc/index.html?/access/helpdes
k/help/techdoc/ref/actxserver.html
Stuart