actxGetRunningServer behavior different between 2013b and 2015b 32bit (Windows 10)

2 Ansichten (letzte 30 Tage)
I frequently work in 2013b and 2015b, both 32bit. I have recently noticed a strange issue after getting a new machine (Windows 10, was previously on Win 7). When I try
Excel = actxGetRunningServer('Excel.Application');
everything works as expected in 2015b 32bit. However, in 2013b, I get:
Error using actxGetRunningServer
The server 'Excel.Application' is not running on this system.
Even though FOR SURE there is an instance of Excel running. If I launch 2015b and 2013b simultaneously, the function will work correctly in 2015b and not in 2013b. The strange thing is, that since I still have access to my old machine, I fired it up - and the function works correctly in BOTH versions. So something to do with Windows 10 maybe?
To make things a bit more complicated, if I create a new instance of Excel through
Excel2 = actxserver('Excel.Application');
Excel = actxGetRunningServer('Excel.Application');
This second call to actxGetRunningServer will find the running (newly created) server correctly. Not really sure what's going on here, hoping someone has an idea.

Akzeptierte Antwort

Nick Heinz
Nick Heinz am 15 Feb. 2018
So I don't really have an answer, but I figured I'd post an update for posterity.
Two days ago I had my boot drive completely fail and was forced to replace it. After a re-install of Windows and all applications (both 2013b and 2015b included), I no longer have the issue. Can't point to a solution other than wiping your entire machine, so again, not a very helpful post...

Weitere Antworten (1)

Dave Watson
Dave Watson am 12 Aug. 2019
Bearbeitet: Dave Watson am 12 Aug. 2019
Well, I don't know exactly why either but I have experienced something similar. It seems Mtalab no longer connects to Excel, PowerPoint that were started outside of Matlab. This was not always the case I I don't remember if it's due to W10 changes (from W7) or the Matlab version - it would be be nice if MW would weigh in on this. Also, Matlab will not execute actxserver if PPT is running outside Matlab???? Didn't check Excel, just gave up and stopped trying to use actxGetRunningSever and put the other in a try block to throw a warning if PPT running on the outside. Seems like a lot of unnecessary trouble.

Kategorien

Mehr zu MATLAB Report Generator finden Sie in Help Center und File Exchange

Produkte

Community Treasure Hunt

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

Start Hunting!

Translated by