<HTML dir=ltr><HEAD><TITLE>Problems with key press interaction in Decision icon</TITLE>
<META http-equiv=Content-Type content="text/html; charset=unicode">
<META content="MSHTML 6.00.6000.16850" name=GENERATOR>
<STYLE>
<!--
font-face
        {font-family:Wingdings;}
font-face
        {font-family:"Cambria Math";}
font-face
        {font-family:Calibri;}
font-face
        {font-family:Tahoma;}
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
a:link, span.MsoHyperlink
        {
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {
        color:purple;
        text-decoration:underline;}
p
        {
        margin-right:0in;
        margin-left:0in;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
span.EmailStyle18
        {
        font-family:"Calibri","sans-serif";
        color:#1F497D;
        font-weight:normal;
        font-style:normal;
        text-decoration:none none;}
.MsoChpDefault
        {
        font-size:10.0pt;}
div.Section1
        {page:Section1;}
ol
        {margin-bottom:0in;}
ul
        {margin-bottom:0in;}
-->
</STYLE>
</HEAD>
<BODY lang=EN-US vLink=purple link=blue>
<DIV id=idOWAReplyText70040 dir=ltr>
<DIV dir=ltr><FONT face=Arial color=#000000 size=2>use a normal event response, but listen for rootIcon, onKeyDown.</FONT></DIV>
<DIV dir=ltr><FONT face=Arial size=2></FONT> </DIV>
<DIV dir=ltr><FONT face=Arial size=2>I also had trouble when trying to handle anyIconID.onKeyDown. RootIcon has some code to make it work - the other icons were problematic for some reason that I can't recall, and led to the things you describe.</FONT></DIV><FONT face=Arial size=2></FONT></DIV>
<DIV dir=ltr><FONT face=Arial size=2>It measn you can only have one listener for onKeyDown, so you might need some if... then... stuff going on in the response.</FONT>
<DIV dir=ltr><BR></DIV>
<DIV dir=ltr>
<HR tabIndex=-1>
</DIV>
<DIV dir=ltr><FONT face=Tahoma size=2><B>From:</B> xerte-bounces@lists.nottingham.ac.uk on behalf of Paul Swanson<BR><B>Sent:</B> Fri 17/07/2009 21:53<BR><B>To:</B> Xerte discussion list<BR><B>Subject:</B> RE: [Xerte] Problems with key press interaction in Decision icon<BR></FONT><BR></DIV></DIV>
<DIV>
<DIV class=Section1>
<P class=MsoNormal><SPAN style="FONT-SIZE: 11pt; COLOR: #1f497d; FONT-FAMILY: 'Calibri','sans-serif'">I don’t understand what you mean by don’t try and handle it from individual icons. Should I not use an event response? Do I use a script icon with if (rootIcon.onKeyDown) { displayPromt.nextPage(); } in a framework entry pane?</SPAN></P>
<P class=MsoNormal><SPAN style="FONT-SIZE: 11pt; COLOR: #1f497d; FONT-FAMILY: 'Calibri','sans-serif'"></SPAN> </P>
<DIV style="BORDER-RIGHT: medium none; PADDING-RIGHT: 0in; BORDER-TOP: medium none; PADDING-LEFT: 4pt; PADDING-BOTTOM: 0in; BORDER-LEFT: blue 1.5pt solid; PADDING-TOP: 0in; BORDER-BOTTOM: medium none">
<DIV>
<DIV style="BORDER-RIGHT: medium none; PADDING-RIGHT: 0in; BORDER-TOP: #b5c4df 1pt solid; PADDING-LEFT: 0in; PADDING-BOTTOM: 0in; BORDER-LEFT: medium none; PADDING-TOP: 3pt; BORDER-BOTTOM: medium none">
<P class=MsoNormal><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Tahoma','sans-serif'">From:</SPAN></B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Tahoma','sans-serif'"> xerte-bounces@lists.nottingham.ac.uk [mailto:xerte-bounces@lists.nottingham.ac.uk] <B>On Behalf Of </B>Julian Tenney<BR><B>Sent:</B> Friday, July 17, 2009 1:37 PM<BR><B>To:</B> Xerte discussion list<BR><B>Subject:</B> RE: [Xerte] Problems with key press interaction in Decision icon</SPAN></P></DIV></DIV>
<P class=MsoNormal> </P>
<DIV id=idOWAReplyText91385>
<DIV>
<P class=MsoNormal><SPAN style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: 'Arial','sans-serif'">you should handle rootIcon.onKeyDown, don't try and handle it from individual icons.</SPAN></P></DIV></DIV>
<DIV>
<P class=MsoNormal> </P>
<DIV class=MsoNormal style="TEXT-ALIGN: center" align=center>
<HR align=center width="100%" SIZE=2>
</DIV>
<P class=MsoNormal style="MARGIN-BOTTOM: 12pt"><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Tahoma','sans-serif'">From:</SPAN></B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Tahoma','sans-serif'"> xerte-bounces@lists.nottingham.ac.uk on behalf of Paul Swanson<BR><B>Sent:</B> Fri 17/07/2009 19:03<BR><B>To:</B> xerte@lists.nottingham.ac.uk<BR><B>Subject:</B> [Xerte] Problems with key press interaction in Decision icon</SPAN></P></DIV>
<DIV>
<P><SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">I’m having problems using</SPAN> <SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">an</SPAN> <SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">onKeyDown event to move to the next page of a Decision icon. It works on the first page, but on the second page, when you press a key, the Decision icon goes wacko and</SPAN> <SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">zips instantly through the rest of the pages and then seems to loop on the icons that follow</SPAN> <SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">the Decision icon.</SPAN> <SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">I haven’t even put onKeyDown events yet on the Decision icon pages that zip through</SPAN> <SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">– those have timed events (which I am attempting to change to</SPAN> <SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">“press any key to continue” onKeyDown events).</SPAN></P>
<P><SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">Properties of my Decision icon:</SPAN></P>
<P style="MARGIN-LEFT: 1in"><SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">id: displayPrompts</SPAN></P>
<P style="MARGIN-LEFT: 1in"><SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">repeat: all</SPAN></P>
<P style="MARGIN-LEFT: 1in"><SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">branch: sequence</SPAN></P>
<P style="MARGIN-LEFT: 1in"><SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">pause: 1</SPAN></P>
<P style="MARGIN-LEFT: 1in"><SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">erase: 0</SPAN></P>
<P style="MARGIN-LEFT: 1in"><SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">eraseOnExit: 0</SPAN></P>
<P><SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">The keypress interaction is NOT perpetual.</SPAN></P>
<P><SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">Properties of the event response:</SPAN></P>
<P style="MARGIN-LEFT: 1in"><SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">eventName: onKeyDown</SPAN></P>
<P style="MARGIN-LEFT: 1in"><SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">icon: rootIcon</SPAN></P>
<P style="MARGIN-LEFT: 1in"><SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">erase: 1</SPAN></P>
<P style="MARGIN-LEFT: 1in"><SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">exit: 0</SPAN></P>
<P><SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">Contents of script icon attached to event response:</SPAN></P>
<P style="MARGIN-LEFT: 1in"><SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">displayPrompts.nextPage();</SPAN></P>
<P><SPAN style="FONT-FAMILY: 'Calibri','sans-serif'">Is there some way to set KeyDown to FALSE or something? Any advise appreciated.</SPAN></P>
<P><SPAN style="FONT-SIZE: 10pt; COLOR: gray; FONT-FAMILY: 'Courier New'">_____________________________</SPAN> </P>
<P><SPAN style="FONT-SIZE: 10pt; COLOR: gray; FONT-FAMILY: 'Calibri','sans-serif'"> </SPAN><SPAN style="FONT-SIZE: 10pt; COLOR: gray; FONT-FAMILY: 'Courier New'">Paul Swanson</SPAN><SPAN style="FONT-FAMILY: 'Calibri','sans-serif'"><BR></SPAN><SPAN style="FONT-SIZE: 10pt; COLOR: gray; FONT-FAMILY: 'Calibri','sans-serif'"> </SPAN><SPAN style="FONT-SIZE: 10pt; COLOR: gray; FONT-FAMILY: 'Courier New'">Instructional Designer</SPAN><SPAN style="FONT-FAMILY: 'Calibri','sans-serif'"><BR></SPAN><SPAN style="FONT-SIZE: 10pt; COLOR: gray; FONT-FAMILY: 'Calibri','sans-serif'"> </SPAN><SPAN style="FONT-SIZE: 10pt; COLOR: gray; FONT-FAMILY: 'Courier New'">Harland Financial Solutions</SPAN><SPAN style="FONT-FAMILY: 'Calibri','sans-serif'"><BR></SPAN><SPAN style="FONT-SIZE: 10pt; COLOR: gray; FONT-FAMILY: 'Calibri','sans-serif'"> </SPAN><SPAN style="FONT-SIZE: 10pt; COLOR: gray; FONT-FAMILY: 'Courier New'">Paul.Swanson@harlandfs.com</SPAN><SPAN style="FONT-FAMILY: 'Calibri','sans-serif'"><BR></SPAN><SPAN style="FONT-SIZE: 10pt; COLOR: gray; FONT-FAMILY: 'Courier New'">_____________________________</SPAN><SPAN style="FONT-FAMILY: 'Calibri','sans-serif'"> </SPAN></P></DIV></DIV></DIV></DIV></BODY></HTML>