Thanks for the response Aaron. Actually, I had pretty much copied the example code from the onCursorKey into my script a long time ago, so I forgot when it came time to execute the cursorkey I had intercepted, it wasn't doing it for the backspace; that's why it wasn't working in Word all the sudden. Which I'm afraid, leads me to say that I think it should have worked just fine; that is, given your explanation, the backspace action should have taken place before I intercepted that key, and nothing I could have done should have been able to stop it, right? And I was not executing it a second time, because I was using your example. I'd guess onCursorKey is able to intercept and stop even the backspace actions; at least that's how it looks to me, and seems what I've accidently proven? Chip
_____ From: Aaron Smith [mailto:[email protected]] Sent: Saturday, April 03, 2010 6:11 PM To: [email protected] Subject: Re: a scripting issue with intercepting cursoring keys Chip, The first action of Backspace is typically (or at least in Notepad) set to be Prior Character Before, which means that it's going to do its stuff before the application sees the key. That also means that IsBeforeApplication is going to be True, which means you need to handle the key different from most of the others. The custom read line example in the OnCursorKey documentation demonstrates how to do this generally without having to look for a specific key. Aaron On 4/3/2010 4:35 PM, Chip Orange wrote: Hi GW and anyone else, I was hoping for some opinions as to what is causing my scripting problem in the MS Word script. it's that I intercept all scripting keys with onCursorKey and return true, insert some extra speech sometimes, then use the .execute method of the key so that the WE speech that resulted from this keypress will occur. the only reason I'm doing it this way is so I can sometimes insert my extra speech before WE gets to speak (just like my wife does!) Anyway, this works fine for all cursoring keys except the backspace key. what happens there, even when my script doesn't add any speech, is that backspace no longer speaks the character you've just spaced over. I've worked around it by specifically testing for the backspace and excluding it from those I intercept, but I'd like to understand what's happening with backspace, so it doesn't bite me again with some other key. Is this just a matter of timing, and the very slight delay I introduce by intercepting the key with onCursorKey and then executing it later? thanks. Chip -- Aaron Smith Product Support Specialist * Web Development GW Micro, Inc. * 725 Airport North Office Park, Fort Wayne, IN 46825 260-489-3671 * gwmicro.com To insure that you receive proper support, please include all past correspondence (where applicable), and any relevant information pertinent to your situation when submitting a problem report to the GW Micro Technical Support Team.
