My question is very simple. I want to make my custom submit button inactive till all the drop items in a drag and drop interaction are placed (all the holes are filled). The submit button only then becomes active so the user cannot submit a partially complete board.
How does one check if an item is 'dropped' or not? Any suggestions?
What happens if after the submit button is shown, the user moves one or more of the objects placed? he could then submit even though some objects are not placed....
for me this is a big issue which i still haven't been able to solve.
You're right, once the submit button is active, they could move an item again. Could you add an additional trigger to track a variable when an item is dragged over say an invisible hotspot? Maybe its a hotspot line below all the drop targets?
To remedy this - set up drop areas just under the starting point of your draggable item. In options - remove the 'return to original position' option. (the wording isn't exact but that is the general idea) then ensure that draggable items always snap to a drop area.
Option 1:
If they are dropped on an answer drop area - evaluate a variable to true (logically tied to the draggable item) and if it is dropped in a starting drop area evaluate a variable to false. You can then check to see if each variable is true on a trigger "when dropped." This variable tracks if it is dropped - you then make a second variable to evaluate if it is correct. (I use "is01dropped" and "is01correct" as my variable names for each draggable item)
Option 2:
If they are dropped on an answer drop area, add +1 to a number variable (logically tied to the draggable item) and if it is dropped in a starting drop area detract -1 from the number variable. You can then check to see if the count of the variable matches the number of your draggable items on a "when dropped" trigger. You then make a second variable per draggable item to evaluate if it is correct. (I use "dropCount" and "is01correct" as my variable names)
5 Replies
Alas,
It seems that you can create a variable that tracks when a drag item is in a drop zone by using the 'Object dropped on' clause... nice!
Problem solved.
What happens if after the submit button is shown, the user moves one or more of the objects placed? he could then submit even though some objects are not placed....
for me this is a big issue which i still haven't been able to solve.
Hi Yoni,
You're right, once the submit button is active, they could move an item again. Could you add an additional trigger to track a variable when an item is dragged over say an invisible hotspot? Maybe its a hotspot line below all the drop targets?
To remedy this - set up drop areas just under the starting point of your draggable item. In options - remove the 'return to original position' option. (the wording isn't exact but that is the general idea) then ensure that draggable items always snap to a drop area.
Option 1:
If they are dropped on an answer drop area - evaluate a variable to true (logically tied to the draggable item) and if it is dropped in a starting drop area evaluate a variable to false. You can then check to see if each variable is true on a trigger "when dropped." This variable tracks if it is dropped - you then make a second variable to evaluate if it is correct. (I use "is01dropped" and "is01correct" as my variable names for each draggable item)
Option 2:
If they are dropped on an answer drop area, add +1 to a number variable (logically tied to the draggable item) and if it is dropped in a starting drop area detract -1 from the number variable. You can then check to see if the count of the variable matches the number of your draggable items on a "when dropped" trigger. You then make a second variable per draggable item to evaluate if it is correct. (I use "dropCount" and "is01correct" as my variable names)
Hope this helps. Rock on.
Hi Holly,
Nice solutions! Thanks for sharing them here.
This discussion is closed. You can start a new discussion or contact Articulate Support.