8 Replies
Greg Hagar

Hi Wendy,

Thanks for the response - that is about half of what I'm asking, but not quite the whole of it. :)

I understand how to trigger actions when an object is clicked on, but what I'm looking to do is trigger an action when the user presses the tab key to move to the next object on the slide.

Imagine an input form where the user moves from field to field by pressing the tab key.  To simulate this in SL, I would create a "text entry" object to represent each of the form fields and set the tab order of those text entry fields to match the flow of the form.

As the user moves through the form, I would provide feedback on their input (by checking it against the variable associated with each text entry field. Typically, I do this using a "when control loses focus" trigger on the field being validated, and that's all good.

In this case I need to do something subtly different - I don't want to validate the user input as soon as the current field loses focus, I want to validate it when the next field on the form gains focus.  If the user is only using the mouse to move to the next field, this isn't a problem, because as you've demonstrated, I can just use the "when user clicks" trigger. Where I get stuck with this is if the user tabs to the next field - there is no equivalent of the "when user clicks" trigger for an object that gains focus via tab order. 

I've added a very simplified example of what I'm describing to the file you shared. I've attached it to this post.

Thanks again for your help and attention!


Greg Hagar

Hi Phil, great point about accessibility - what I'm describing would be quite helpful from that perspective!

I assumed what I was hoping to do wasn't really possible yet, but I thought I'd see what community had to say just in case - they've certainly provided some fantastic insight in the past (and will in the future I'm sure)!  

Fiona Macelli

I believe that what Greg was looking for was something to activate the trigger without selecting the object (using the keyboard or otherwise), just having it be "in focus" via the tab key.  That is what I'm looking for anyway.

I wouldn't exactly call it a critical feature, since for accessibility reasons you would not normally want to have something new appear onscreen without the user having done something explicitly to cause the change. But it would be helpful in my current project to have something like this in order to make a particular activity accessible.  And from what I understand of Greg's thread, it would be useful for simulating a form-entry.

I have been able to get satisfactory results using the 'key press' trigger and setting the key to be pressed as the 'tab' key.  It doesn't trigger quite when I want it to, and it doesn't work in reverse order (when tabbing backwards through the tab order). Assigning both tab and shift to activate the trigger on key-press doesn't seem to be accepted even though the trigger panel does let me enter the key combination.

All this is to say: thanks for the suggestion Leslie, but it doesn't meet my current need; it's an uncommon use case and there's lots of other feature requests that would take priority; and if anyone else is trying to do something similar, the key-press trigger has worked the best.