Aaron, Have you had time to get the CursorKeyAction.ActionID property to work? As I said in my previous post on this subject, I got it to work with the Description property. If ActionID does not work, this is a bug. It is supposed to return an Enum. An Enum is stored in a text variable, right? If it works for you, let me know how to use it. Also, as I said previously, the Description property is not giving me accurate information on some cursor keys. I gave specifics in my last message. Let me know please.
Thank you. Vic -----Original Message----- From: Aaron Smith [mailto:[email protected]] Sent: Saturday, January 31, 2009 5:57 PM To: [email protected] Subject: Re: OnCursorKey Event Vic, You should print out the type name of objAction1 to verify that you got a CursorKeyAction object. Aaron Vic Beckley wrote: > Can anyone tell me why this script will not work? > > > > Dim CursorKeyEvent : CursorKeyEvent = ConnectEvent(Application, > "OnCursorKey", "OnCursorKey") > > > > Function OnCursorKey(CursorKeyId, isBeforeAction, defaultActionAborted) > > If isBeforeAction Then > > Dim objAction1 : Set objAction1 = CursorKeyId.FirstAction > > Dim objAction2 : Set objAction2 = CursorKeyId.SecondAction > > Dim strAction1 : strAction1 = objAction1.ActionID > > Dim strAction2 : strAction2 = objAction2.ActionID > > Speak strAction1 > > Speak strAction2 > > End If > > OnCursorKey = False > > End Function > > > > I get this error when I use a cursor key with the script running. > > > > CursorKeyTest.vbs - Microsoft VBScript runtime error > > Line 7 Column 18 > > Object doesn't support this property or method: 'objAction1.ActionID' > > > > < 0x800A01B6 > > > > > Vic > > > -- 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. Aaron Smith GW Micro Phone: 260/489-3671 Fax: 260/489-2608 WWW: http://www.gwmicro.com FTP: ftp://ftp.gwmicro.com Technical Support & Web Development __________ NOD32 3815 (20090131) Information __________ This message was checked by NOD32 antivirus system. http://www.eset.com
