[jawsscripts] running hotspots from a script, was Moving the mouse to a spesific location

Hi GianniP46.

I'm sooooo sorry I've left this for soooo long to answer, but, I wanted to
test it first to make sure I was right, and ... well I know, I should've
done it ages ago!
I do apologize for this.

The answer to your question is yes, you can run a hotspot midScript, and the
magic function you use to do this is:

HscLookupKey ("Put hotspot's TopLine bracketed header in quotes here")

now of course one normally attaches a key to activate a hotspot in hsc, and
this will typically be the string in the topLine bracketed header of the
hotspot definition.
but of course it need not be.
one doesn't have to atach any key to a hotspot of course. One can answer no
to the question in the wizard when asked, and in that case, the bracketed
header will typically repeat the actual hotspot name or label. see bits cut
out of the very useful hsc parameter reference, found under the start menu
under the hotspotClicker entry:

Bracketed Header

This field is always enclosed in brackets, and is the name by which the
hotspot is accessed. For example:
[Control+Shift+2]
Typically, this is the hotkey to which this hotspot is attached. If so, you
can change the hotkey assignment by changing the letters between the
brackets.
Always list key modifiers in the following order: Control, Alt, Shift,
Windows, with plus signs "+" between..
However, if the spot is not connected to a hotkey, this is simply the name
by which the spot is referenced, and is typically identical to the label.

label

This is a human readable string of text which should describe the purpose of
the hotspot. Optionally, this label can be spoken each time the hotspot is
activated, depending on the setting of the Enunciation parameter.

----- Original Message ----- 
From: "GianniP46" <giannip46@xxxxxxxxxxxxx>
To: <jawsscripts@xxxxxxxxxxxxx>
Sent: Tuesday, November 04, 2008 7:18 AM
Subject: [jawsscripts] Re: Moving the mouse to a spesific location


> Does anyone know how to move to a hotspot from with in a script?
>   ----- Original Message ----- 
>   From: Jackie McBride
>   To: jawsscripts@xxxxxxxxxxxxx
>   Sent: Monday, November 03, 2008 1:54 PM
>   Subject: [jawsscripts] Re: Moving the mouse to a spesific location
>
>   Matthew, my responses are interspersed w/your questions, below.
>
>   Because I'm looking to do something similar to what Johnny's attempting,
can
>   I use the name of an icon and employ the FindGraphic script as you
suggested
>   below to write a script that toggles this graphic icon on and off? as
is, I
>   currently use the same identical manual commands via jaws cursor to
>   repeatedly get to the icon and click it on or off.
>
>   Yes. Note that case matters in this function, so be sure to get that
>   right. The pseudocode would look something like:
>   SaveCursor()
>   JawsCursor()
>   routeJawsToPc()
>   JawsPageUp()
>   if (FindGraphic(GetCurrentWindow(),"IconName",s_top, s_Unrestricted))
then
>   pause()
>   LeftMouseButton()
>   endif
>   RestoreCursor()
>
>   U might also wanna put in an else followed by a saystring function for
>   debugging purposes, e.g., in case the icon was not found, then you'd
>   know that & could change the window handle from GetCurrent to
>   something more appropriate, begin the search from the bottom as
>   opposed to the top, or check your capitalization, etc. It can be
>   removed when you've got it right.
>
>   I'm also wondering if it is possible to relabel an icon to make it
easier
>   for jaws to find? The goal being minimizing bad findGraphic results.
>
>   If u can label it w/the jaws graphics labeler, then, yes.
>
>   I was thinking of using some sort of jaws scripting command to change
>   the name of
>   something like "lock" to "lock my file" in order for jaws' findGraphic
>   function to do its job with ease and accuracy. I'm thinking any words on
the
>   screen can not be changed as they are a part of the application's code
>   therefore Jaws cannot change this hard wiring in any way. Is this right
or
>   wrong?
>
>   Again, Matthew, this depends on whether or not jaws has labeled this
>   graphic or the application has. 1 other thing that may or may not be
>   useful here, depending on the app, is something like getObjectName or
>   GetFocusedObject, as the case may warrant, e.g., the icon may actually
>   be an object. Homerow f9 or alt f9 may help u in dealing w/that aspect
>   of it. Doug Lee's BX ToolBox is also an excellent tool for exploring
>   applications, but is probably for those fairly advanced in the art of
>   scripting. If that's you, I'd get it for certain. Jamal Mazrui's
>   Windig can also help u isolate where the icon is in a window.
>
>   Again, if the icon has its own separate controlID, then this may be an
>   even better way to approach it than FindGraphic.
>
>   As u can see, lots of roads lead to Rome, & everything really depends
>   on how the particular app is structured.
>
>   On 11/3/08, Matthew2007 <matthew2007@xxxxxxxxxxx> wrote:
>   > Jacky,
>   >
>   > Because I'm looking to do something similar to what Johnny's
attempting, can
>   > I use the name of an icon and employ the FindGraphic script as you
suggested
>   > below to write a script that toggles this graphic icon on and off? as
is, I
>   > currently use the same identical manual commands via jaws cursor to
>   > repeatedly get to the icon and click it on or off. Your find graphic
>   > solution sounds like it will do what I want in a faster way using a
search
>   > than the manual way I'm using now.
>   >
>   > I'm also wondering if it is possible to relabel an icon to make it
easier
>   > for jaws to find? The goal being minimizing bad findGraphic results. I
was
>   > thinking of using some sort of jaws scripting command to change the
name of
>   > something like "lock" to "lock my file" in order for jaws' findGraphic
>   > function to do its job with ease and accuracy. I'm thinking any words
on the
>   > screen can not be changed as they are a part of the application's code
>   > therefore Jaws cannot change this hard wiring in any way. Is this
right or
>   > wrong?
>   >
>   > Thanks,
>   >
>   > Matthew
>   >
>   > ----- Original Message -----
>   > From: "Jackie McBride" <abletec@xxxxxxxxx>
>   > To: <jawsscripts@xxxxxxxxxxxxx>
>   > Sent: Monday, November 03, 2008 9:04 AM
>   > Subject: [jawsscripts] Re: Moving the mouse to a spesific location
>   >
>   >
>   >> Giani:
>   >>
>   >> The MoveTo function does what u want. However, the caveat to
>   >> coordinate-based location is that if the resolution changes, the
>   >> script breaks.
>   >>
>   >> If u can label a graphic & then do a FindGraphic, that might be a
better
>   >> way.
>   >>
>   >> On 11/3/08, GianniP46 <giannip46@xxxxxxxxxxxxx> wrote:
>   >>> Hey folks,
>   >>> I am trying to write a script where I need to move the mouse to a
>   >>> specific
>   >>> location.  Should I either use the coordinates of the spot to move
the
>   >>> mouse
>   >>> there?  If so, is there  a function that will put the mouse at a set
of
>   >>> coordinates?
>   >>> Or I was thinking since I have a hotspot already, is there a
function or
>   >>> script that I can call with in a script that will move the mouse to
a
>   >>> hotspot.  I do have the latest version of HSC installed.  Any ideas?
>   >>> THANKS!
>   >>>
>   >>> Gian Pedulla GianniP46@xxxxxxxxxxxxx
>   >>>
>   >>> LETS! GO! METS!
>   >>> __________
>   >>> Visit and contribute to The JAWS Script Repository
http://jawsscripts.com
>   >>>
>   >>> View the list's information and change your settings at
>   >>> http://www.freelists.org/list/jawsscripts
>   >>>
>   >>>
>   >>
>   >>
>   >> --
>   >> Change the world--1 deed at a time
>   >> Jackie McBride
>   >> Check out my homepage at:
>   >> www.abletec.serverheaven.net
>   >> & please join my fight against breast cancer
>   >> <http://teamacs.acsevents.org/site/TR?px90196&pg=personal&fr_id489>
>   >> __________
>   >> Visit and contribute to The JAWS Script Repository
http://jawsscripts.com
>   >>
>   >> View the list's information and change your settings at
>   >> http://www.freelists.org/list/jawsscripts
>   >>
>   >>
>   >
>   > __________
>   > Visit and contribute to The JAWS Script Repository
http://jawsscripts.com
>   >
>   > View the list's information and change your settings at
>   > http://www.freelists.org/list/jawsscripts
>   >
>   >
>
>
>   -- 
>   Change the world--1 deed at a time
>   Jackie McBride
>   Check out my homepage at:
>   www.abletec.serverheaven.net
>   & please join my fight against breast cancer
>   <http://teamacs.acsevents.org/site/TR?px90196&pg=personal&fr_id489>
>   __________
>   Visit and contribute to The JAWS Script Repository
http://jawsscripts.com
>
>   View the list's information and change your settings at
>   http://www.freelists.org/list/jawsscripts
>
>
>
>   -- 
>   No virus found in this incoming message.
>   Checked by AVG.
>   Version: 7.5.549 / Virus Database: 270.8.5/1764 - Release Date:
11/3/2008 7:46 AM
>
> __________
> Visit and contribute to The JAWS Script Repository http://jawsscripts.com
>
> View the list's information and change your settings at
> http://www.freelists.org/list/jawsscripts
>

__________ 
Visit and contribute to The JAWS Script Repository http://jawsscripts.com

View the list's information and change your settings at 
http://www.freelists.org/list/jawsscripts

Other related posts: