Hi Janne,

Rather than the AddHookFunction, which I think may not be suited for your 
purpose, consider the following.

If you simply want a script to stop part way through, so you can examine the 
screen contents at that point, insert the following line at the point in 
your script  where you want it to stop.

IF 1 THEN RETURN ENDIF; for testing only

and semi colon out the line when not needed.

If you want to examine the contents of some variables part way through a 
script, and perhaps after continueing the scripts operation for some more 
lines, then again look at the variable values, try the following method.

Just call this function from where you want to check the values...

Note. in the below sample copied from one of my script sets, the variables 
are integers, but you can soon simplify it for strings.  It uses the virtual 
buffer, but instead, you could use the MessageBox function passing in, 
CurrentValues.

include "common.jsm" ; for virtual buffer...

Function ListVariables ()

; lists the current value of particular variables. Used for debugging

VAR

STRING CurrentValues



; Note the \N causes a new line, otherwise it would all be on 1 line



LET CurrentValues =

"CharWidth = " + IntToString (G_CharWidth) +

"\NOnePoint5CharSquared = " + IntToString (G_OnePoint5CharSquared) +

"\NRowHeight = " + IntToString (G_RowHeight) +

"\NHalfRowHeight = " + IntToString (G_HalfRowHeight) +



cScBufferNewLine + cScBufferNewLine +

cMsgBuffExit

If UserBufferIsActive () then

UserBufferDeactivate ()

EndIf

Pause ()

SayFormattedMessage (OT_USER_BUFFER, CurrentValues)

EndFunction



As mentioned in an earlier post, the JawsScripting list may be a better 
forum for this type of enquiry...



Regards,

Paul from Aust.



----- Original Message ----- 

From: "Datapunkt Info" <[EMAIL PROTECTED]>


Hello list.

I am new to this list. I am interested in script programming and have a 
question.

In a script I am writing on, i need the script to just stand still and check 
my keyboard entries an compare them to different string variables. I think 
that the AddHook () would be the thing to use. I have read the documentation 
and have looked at it in the default.jss file but i can't really understand 
it. If anyone on this list can make my small brain to understand how to use 
it, please help me.

Thanks in advance, Janne


Visit the JAWS Users List home page at:
http://www.jaws-users.com
Address for the list archives:
http://www.mail-archive.com/jaws-users-list@jaws-users.com
To post to this group, send email to 
jaws-users-list@jaws-users.com
To unsubscribe from this group, send an email to 
[EMAIL PROTECTED]
For help from Mailman with your account Put the word help in the subject or 
body of a blank message to:
[EMAIL PROTECTED]
Use the following form in order to contact the management team
http://www.jaws-users.com/managers.php
If you wish to join the Blind Computing list send a blank email to the 
following address:
[EMAIL PROTECTED]
 

Reply via email to