On 2/22/2010 9:27 PM, Chip Orange wrote:
I don't know the technical reason as to why, but when I tried this, it does not work. so, you'll have to use createobject.

The technical reason is that on Windows Vista and above, Windoweyes.Application is - believe it or not - an in-process server. It had to be done that way so that you can create one regardless of the integrity level of your process. Previously, it was an out-of-process server that was exposed through the weserv service, but that caused problems for clients using a multithreaded apartment model (most notably, Windows Powershell.) Anyway, inproc servers don't work with GetActiveObject for fairly obvious reasons. On Windows 2000 and Windows XP, Windoweyes.Application is an out-of-process server as you'd expect, but we felt it'd be confusing if we registered with the running object table on some operating systems but not others.

there is another object that you can use, documented on the wiki or the knowledgebase I think, which allows you to determine if window eyes is already running if that's your real aim.


http://www.gwmicro.com/mediawiki/index.php/General_Software_Accessibility_Guidelines#Working_With_Window-Eyes

Not mentioned there is that the gwspeak.speak object now has a property, IsRunning, that can tell you whether Window-Eyes is running. However, older versions of Window-Eyes did not support that property, so you should be prepared to trap DISP_E_MEMBERNOTFOUND errors.


Reply via email to