First,Last & Goto Navigations

Recently we were asked why do we have a GOTO button. In this post we will discover exactly what it does and how we can take advantage of its features. We will also look at the two other buttons that go with the goto button and they are the last and first buttons.

To start with we need some metadata , so here is a few test questions.

Metadata(en-AU, Question, label)
Q1 "Q1. Text" categorical [1]
    {
    	A,B
    };

Q2 "Q2. Text" categorical [1]
    {
    	C,D
    };

Q3 "Q3. Text" categorical [1]
    {
    	E,f
    };

Q4 "Q4. Text" categorical [1]
    {
    	G,H
    };

End Metadata

And then this is the routing that we are going to use,

Routing(Web)

IOM.Navigations.Add(NavigationTypes.nvFirst)
IOM.Navigations.Add(NavigationTypes.nvLast)
IOM.Navigations.Add(NavigationTypes.nvGoto)

q1.ask()
q2.ask()
q3.ask()
q4.ask()

End Routing

So what do we see when we run the survey in Professional, well , to start with we see this

Survey Start

Answer the next two questions and make sure you end up with this screen,

First , Last & Goto buttons

So if we click the first button we jump all the way back to the first question in the survey that we answered.

Use of first button

And if you click the last button next , you will find that you jump to the last question that was answered.

Use of last button

So that just leaves the goto button and as you should have seen by now as we progress through the survey the list of questions on the goto button gets bigger with the questions you have answered and if you select one of the questions in the list it jumps you straight to that question.

Goto Button

Here are some questions and their answers.

Q. Does the dropdown list for the Goto button only contain those questions have answered using .Ask(), or does it show all the questions with offpath.Response?

Using the following routing,

q1.ask()
if ( q1 = {a} ) then 
	q2.ask()
End iF
q3.ask()

and not selecting a at Q1 , we can see that q2 is not displayed in the goto,

No Question 2

Q. How about the questions use .Show(). For example, if we use info question type and .Show() to list some definition, will that be included in the dropdown list?

So making q3 a .show() we get this,

Using a show

Q. If we have some auot-filled interim variables set up for scripting or analysing only, will they be included in the list after passing them in the routing?
So using this routing,

q4 = {h}
q1.ask()
if ( q1 = {a} ) then
	q2.ask()
End iF
q3.show()

we get ,

No Q4

5 thoughts on “First,Last & Goto Navigations”

  1. This is really helpful. thanks for sharing! just wondering, does the dropdown list for the Goto button only contain those questions have answered using .Ask()? Or does it show all the questions with offpath.Response? how about the questions use .Show()? for example, if we use info question type and .Show() to list some definition, will that be included in the dropdown list? another example, if we have some auot-filled interim variables set up for scripting or analysing only, will they be included in the list after passing them in the routing?

  2. Could we have the Goto just show a single destination? For example, if I have a menu through which I want the give the respondent the chance to choose which product to evaluate, I may have to override and go back to this menu before they finish that section. if using this Goto navigation wouldn’t work, do you have any suggestions?

Leave a Comment

%d bloggers like this: