How to store an actxserver variable in Simulink

I have a simulink model where on the first iteration i want to open up an actxsever for excel Then on other iterations i want to 'iterate' on it, by writing to it each iteration, but the problem is, i cant seem to have one matlab function block call it, and another one iterate on it.
In other words, when i do the following... Excel = actxserver('Excel.Applicatoin'); Workbook = Excel.Workbooks.Open(filename); in an MATLAB function block in simulink. I cannot save Excel or Workbook variables to be called elsewhere in the model...
Ive tried DataStore, but it doesnt seem to allow that datatype...
Is there a way to store the variable Excel = actxserver('Excel.Application'); in a block to be used at other points in the model?
Thanks

Réponses (0)

Produits

Question posée :

le 18 Mar 2014

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by