When I uncomment it, it reads the count, and both the sTitle and RealName. They are both the same. My RealName == sTitle in the first part of the if statement is coming back false. Kev ----- Original Message ----- From: "Homme, James" <james.homme@xxxxxxxxxxxx> To: <jawsscripts@xxxxxxxxxxxxx> Sent: Tuesday, February 23, 2010 1:04 PM Subject: [jawsscripts] Re: One Note and Focus Change > Hi Kevin, > What happens when you uncomment the code. > > Jim > > Jim Homme, > Usability Services, > Phone: 412-544-1810 > Skype: jim.homme > Internal recipients, Read my accessibility blog > > -----Original Message----- > From: jawsscripts-bounce@xxxxxxxxxxxxx > [mailto:jawsscripts-bounce@xxxxxxxxxxxxx] On Behalf Of Kevin Mattingly > Sent: Tuesday, February 23, 2010 11:34 AM > To: jawsscripts@xxxxxxxxxxxxx > Subject: [jawsscripts] One Note and Focus Change > > Guys, > I'm trying to have the title of the page in one read when it changes. In > general, you use the control-PageUp and Control-PageDown to move between > pages. When you move between each page, the title of that paget changes > and is listed at the top of the page. I only want it spoken when it > changes and otherwise, I want ti to be silent. I wrote an 'If' statement > and used some varialbes to test and say the title when it changes. I think > the logic is sound but the darn statement always shows up false I may just > be a horrible programmer or just can't see this one. Here's the code I'm > using. If you have an idea of what I'm doing wrong, please pass along a > fix or suggestion. > > > Var > Handle HReal, > Int iCount, > String RealName, > String sTitle, > let GlobalFocusWindow=FocusWindow > let hReal=GetRealWindow(FocusWindow) > Let RealName = GetWindowName (hReal) > If RealName == sTitle && iCount == 1 Then > SayString(RealName) > Else > Let sTitle = RealName > Let iCount = 1 > ; The following are checks for testing > ; SayInteger(iCount) > ; SayString(sTitle) > ; SayString(RealName) > EndIf > __________ > Visit and contribute to The JAWS Script Repository http://jawsscripts.com > > View the list's information and change your settings at > //www.freelists.org/list/jawsscripts > > > This e-mail and any attachments to it are confidential and are intended > solely for use of the individual or entity to whom they are addressed. If > you have received this e-mail in error, please notify the sender > immediately and then delete it. If you are not the intended recipient, > you must not keep, use, disclose, copy or distribute this e-mail without > the author's prior permission. The views expressed in this e-mail message > do not necessarily represent the views of Highmark Inc., its subsidiaries, > or affiliates. > __________ > Visit and contribute to The JAWS Script Repository http://jawsscripts.com > > View the list's information and change your settings at > //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 //www.freelists.org/list/jawsscripts