+1 vote

I’d like to customize what happens when a user skips a question:

For instance:

I ask a user to list all the places they like to eat. I include *blank so that the question can be skipped and save answers to a variable called placesToEat

For some reason this next bit of code is not working for me. THe program isn’t throwing an error however, I’m not seeing my text on the screen.

*if: placesToEat = {}
Oh it's empty in here. Let's help you find a restaurant.
*button: Next
*goto: sendEmail
by (350 points)

1 Answer

+1 vote

Assuming that the question that saves the answers to placesToEat is of *type: checkbox or has *multiple indented under it, placesToEat will be a list/collection (the documentation is here in the manual).

What you would do is to check the size of that list - if your user skipped the question, the size of the list is 0:

*if: placesToEat.size = 0
	Oh it's empty in here. Let's help you find a restaurant.
	*button: Next
by (3.6k points)
Welcome to Guidedtrack Q&A, where you can ask questions and receive answers from other members of the community.
134 questions
144 answers
55 comments
40 users