Forum Discussion

ClaireLepretre's avatar
ClaireLepretre
Community Member
27 days ago
Solved

Labels disappear randomly on a Drag&Drop exercise #JavaScript #Storyline

Hello, 

I have an issue wherein one the 6 labels may sometimes disappear when dropping my drag items.

 

  • Type of exercise: Drag and drop full Java script (not storyline graded question used)

 

  • Goal of exercise: Drop the 6 labels on the left into the truck area on the right, then click "Je valide..." to move on to the next question. 3 questions in total.

 

  • Here's my problem: When I drop one of the 6 labels into the truck, at the boundary between the road and the edge of the dark gray outline of the truck, the label disappears randomly, meaning sometimes it disappears, sometimes not. And only for location number 1 (at the very top of the truck).

 

This bug only appears for "slide 1.3 questions 2" and "slide 1.4 questions 3." Because for "slide 1.2 questions 1," it works correctly (no labels disappear).

I joined the Storyline file and a mp4 demo video of the issue. 

I'd appreciate your feedback.

Thanks a lot.

Claire

  • Hi Claire, 

    as far as I can see, the issue is that the variable VariableDropTemp carries over from the previous slide. So the item that was dropped last on the first question slide will disappear on the second slide if you drag it onto the target first. 

    If you add a trigger that sets the variable to blank when the timeline starts on the second and third question slides, the problem should disappear.  




    Please do test it extensively after adding this trigger to make sure that adding it didn't break anything else.

2 Replies

  • Hi Claire, 

    as far as I can see, the issue is that the variable VariableDropTemp carries over from the previous slide. So the item that was dropped last on the first question slide will disappear on the second slide if you drag it onto the target first. 

    If you add a trigger that sets the variable to blank when the timeline starts on the second and third question slides, the problem should disappear.  




    Please do test it extensively after adding this trigger to make sure that adding it didn't break anything else.

    • ClaireLepretre's avatar
      ClaireLepretre
      Community Member

      Hi Lisa, 

      While waiting for a response, I decided to try to avoid using the same variables from one screen to another. So I created as many new, different variables as needed for each screen. This way, there's no more confusion. It seems to work!
      However, I'll note your solution, which seems to be faster, and I thank you very much for taking the time to answer my question 🙏