Emulating a Double-Click event in HTML

discrepancy
discrepancy Community Member Posts: 1
I do a lot of application simulation training in a web-based LMS, so I often need to allow my users to double-click.



For anyone who has been frustrated by the "OnMouseDoubleClick events not supported for objects" error when publishing to HTML, this little trick is for you.



1. Start by creating a transparent button and positioning it over the area of the screen where you want the user to double click.

2. Once it's in place, copy that button, and paste it on top of itself so that there are two in the exact same position.

3. Give the two buttons different names, something like btn_Click1 and btn_Click2 (or Thing1 and Thing2 if you're a Dr. Seuss fan).

4. Go to the properties for btn_Click2 and un-check "Initially visible" in the General tab. In the On Click tab, set the action you wish your double-click to activate (in my case it's usually Show something, or Go to Next Page).

5. Now go to the properties for btn_Click1. Make sure it is initially visible. In the On Click tab, set it to SHOW btn_Click2.

6. Add an Action to btn_Click1. On Mouse Click, HIDE btn_Click1.



To recap, btn_Click1 now does two things: Show btn_Click2, then hide itself.

btn_Click2 then becomes the button that actually performs the action (like displaying the next screen or menu).



It's not perfect, because a user could click once, get up and take a coffee break, then come back and click a second time, and it will still count as a double-click... but I haven't had any users notice it yet!



Cheers,

Austin

Comments

  • cswalker21
    cswalker21 Community Member Posts: 7
    Yeah, but what if they took the coffee break before they started? I have the opposite problem from the coffee break problem. That is, the second click comes too quickly for the action to be completed, so the button action is never fired.



    I tried both the two-button and the one-button approach and with both I ran into this issue using a natural double-click motion. In essence, I could only get it to work with a very slow, deliberate double-click. I don't want to unleash this on my users. The search continues for a viable workaround.



    I would love to simply use the On Mouse Double Click action, but as others have said, it is not supported when publishing to html/scorm. Maybe Lectora 12?
  • altarium
    altarium Community Member Posts: 78
    I know this is an older thread, but I was wondering if anyone has found a good workaround for double-clicks? As cswalker21 said, the method of clicking button 1 hiding itself and showing a second button only works in a browser with slower, deliberate clicks. I know javascript has a doubleclick event, has anyone successfully integrated this into a lectora course? We're working on a Windows training course and I need to successfully simulate doubleclicking... while publishing the course to SCORM standards...
  • cojocarutudor
    cojocarutudor Community Member Posts: 1
    Very interesting and useful tips.I read step by step this informations and help me very much.Thank you very much for this informations!
Sign In or Register to comment.

So You Wanna Be An eLearning ROCKSTAR?

We're all fans of eLearning here! Want to become an eLearning ROCKSTAR? Just click on one of the buttons below to start your rocking journey!