BTW, class # 16 (when I did a quick search), seems to include a discussion
of getObject().

 

Hth,

 

Chip

 

 

From: Chip Orange [mailto:lists3...@comcast.net] 
Sent: Thursday, October 09, 2014 6:52 AM
To: gw-scripting@gwmicro.com
Subject: RE: GetObject syntax / function

 

Hi Jonathan,

 

There's a trick to use of GetObject(); it does have two parameters, but the
first parameter should not be a null string, but should be omitted entirely
if what you want is to obtain a pointer to any currently running copy of
this application object (see my Word Advanced Features app, which does this,
rather than start up a second copy of Word).  For instance:

 

Set WordApp = getObject(, "word.application")

 

Then, if it ends up returning nothing, you can then use CreateObject() to
start the application.

 

As Steve says, this is standard VBScript, so you can search the internet for
all information on it.

 

 

Hth,

 

Chip

 

 

 

From: Jonathan C. Cohn [mailto:jon.c.c...@gmail.com] 
Sent: Tuesday, October 07, 2014 7:22 AM
To: gw-scripting@gwmicro.com
Subject: GetObject syntax / function

 

I am having issues reproducing a GetObject() command I am using in a JAWS
script to work in WindowEyes. In JAWS  GetObject(R"eflection.Session"). Note
that in JAWS this takes just one argument. After invoking this command I can
act directly with the scriptable objects of the current session. In VBS with
WindowEyes the GetObject requires two parameters, where the second parameter
appears to be equivalent to the parameter that JAWS uses.

 

If I use a null string for the first parameter then Reflection creates a new
hidden window. If I use the path of the Reflections settings file then I get
a new session to the host. If I leave the first parameter completely blank,
I get back an ActiveX error.  What am I missing here?

 

Thanks in advance for any hints.Best wishes,

 

Jonathan

 

 

 

Reply via email to