Forum Discussion

BerenBaumgartne's avatar
BerenBaumgartne
Community Member
8 years ago

Storyline Drag-Drop "Allow only one item..." won't be recognized by intersecting-check

Dear support & community.

I ran into a tricky problem with recognizing, if an draggable object was reset to its original position via the "Allow only one item..." option under the drag-drop settings.

It seems impossible -- tried intersection trigger conditions, state-checks etc...

Attached is an image showcasing the setup and what the issue is.

 

Goal:

To recognize if all drag-drop objects are placed on their targets, no matter if correct or incorrect. Only then the submit function must be executed.

If only one of the drag-drop objects is missing, sumbit must not work.

This must also be true when objects have been dragged out again from their targets and are "snapped" back to their origins.

 

 

What works:

When a user drags the object out of the "intersecting" area manually, everything works as intended: The trigger condition "when: Object intersection ends" recognizes the object being dragged out of the intersecting object (which in this case is the target). => Thus storyline recognizes that not all objects are currently placed on their target areas and submit won't be executed. Great.

 

What doesn't work:

Using the "Allow only one item..." option, which is needed in this case, a user can place an drag-drop object ontop of an object that has already been placed on a target. The old object thus will be "snapped" back onto it's origin automatically. However there seems to be no way to know if this happened! => Thus Storyline still thinks all objects are currently placed on their target areas and submit will be executed(but it shouldn't, since at least one of the object was snapped back to its original state).

 

 

Sadly I can't send a file, but I really hope the issue was described well enough for anyone who ran into the problem and found a solution. Thanks in advance!

16 Replies

  • I see this discussion is a couple of years old - is there a feature solution to this? I also want to disable the Submit button on a drag and drop until ALL draggable items have been place on a target (correct or incorrect).

    AND I'm only allowing one item per target.

    I saw several related discussions about this kind of issue and thought I would try a slightly different approach. Instead of checking if the draggable items intersected with the targets I thought I would check if any were left where they started (I set return to original position if dragged outside a target).

    So when the Submit button is clicked I move a hotspot over the area where the draggable items started and set a variable to true if the hotspot intersects with any of the items. If true the Submit button doesn't operate, I then reset the variable to false and move the hotspot back. That works pretty well. You have to have all the items on targets to be able to submit...

    It even works for me on "Try Again" with no extra code. But I'm always looking for a more elegant solution.

    • IanBuxton-46cc5's avatar
      IanBuxton-46cc5
      Community Member

      Hi John,
      This is an elegant enough solution, and very sneaky. 
      I've got the hotspot test working, but how do I delay the implementation of the submit/next slide until after the test is completed? The slide moves on before the variable is updated to prevent it.
       
       

  • Users: find bugs
    Storyline team:
    anime durmiendo en clase - Buscar con Google | Naruto anime, Arte de  naruto, Naruto bonito

     

    basically the freeform drag and drop is useless if you want to change some states?