Suspending a questionnaire, then performing some task

Problem

You want the respondent to be able to suspend the questionnaire and you want the questionnaire to perform some action after that request.

Solution

The following code suspends the questionnaire and sends an e-mail to the respondent.

    # Bouton stop = oui,INTERRUPT
    TOTERMINE BLANK
    ## This question skips ahead to the end of the questionnaire to isolate the INTERRUPT series
    ## and avoid that one enters it at the end of the interview
    % Question
    % Note
    % Categories

    % Skips
       1 = ~TERMINE
    % Condition
    % Open part
    ! ####################################################################################################
    INTERRUPT NOSTOP
    ## This question is displayed only after clicking the Stop button
    ## The NOSTOP parameter is so that the Stop button is not displayed on that screen
    % Question
       Please enter an e-mail address where we will send you a link to come back to the questionnaire.
    % Note
    % Categories

    % Skips
    % Condition
    % Open part
       1 = E40 1 40
    ! ####################################################################################################
    INTERRUPT2 CALCUL
    ## This question e-mails the text of INTERRUPT3 to the respondent at the AINTERRUPT address
    % Question
       AINTERRUPT2 = email("info\@callweb.ca",$AINTERRUPT,"INTERRUPT3")
    % Note
    % Categories

    % Skips
    % Condition
    % Open part
       1 = C40 1 40
    ! ####################################################################################################
    INTERRUPT3 EMAIL
    ## Text of the e-mail sent out
    % Question
       Resuming your questionnaire
    % Note
       Please click the following link to resume your questionnaire:<P>
       http://{$contexte{host}}{$contexte{script}}?_proj={$_proj}&_lang={$_lang}&_telkey={$_telkey}
    % Categories
    % Skips
    % Condition
    % Open part
    ! ####################################################################################################
    INTERRUPT4 CALCUL
    ## Closes the browser window
    % Question
       dump = ferme_le_navigateur()
    % Note
    % Categories
    % Skips
    % Condition
    % Open part
    ! ####################################################################################################
    TERMINE BLANK
    ## This question ends the questionnaire.
    % Question
    % Note
    % Categories

    % Skips
    % Condition
    % Open part
    ! ####################################################################################################

Discussion

Sometimes, respondents want to stop filling out a questionnaire and resume later. This is easily achieved by re-using a link that was sent with an invitation to take part in the survey if access is password-protected (# Type enquete = 2). However, if access was open or if an access-code was provided upon entry, respondents are unlikely to have the information required to return.

In these circumstances, the Stop button can be displayed with a pound instruction like the following:

    # Bouton stop = oui,INTERRUPT

which activates the Stop button and instructs CallWeb to go directly to the INTERRUPT question once the button is clicked (clicking the Stop button also saves the data already provided on that page but does not validate them).

The interruption destination question can do anything. The following code shows how to request that an e-mail address be supplied and how to send a message containing a link back to the questionnaire — right where the interview left off.

Suspending a questionnaire, then performing some task

Problem

You want the respondent to be able to suspend the questionnaire and you want the questionnaire to perform some action after that request.

Solution

The following code suspends the questionnaire and sends an e-mail to the respondent.

    # Bouton stop = oui,INTERRUPT
    TOTERMINE BLANK
    ## This question skips ahead to the end of the questionnaire to isolate the INTERRUPT series
    ## and avoid that one enters it at the end of the interview
    % Question
    % Note
    % Categories

    % Skips
       1 = ~TERMINE
    % Condition
    % Open part
    ! ####################################################################################################
    INTERRUPT NOSTOP
    ## This question is displayed only after clicking the Stop button
    ## The NOSTOP parameter is so that the Stop button is not displayed on that screen
    % Question
       Please enter an e-mail address where we will send you a link to come back to the questionnaire.
    % Note
    % Categories

    % Skips
    % Condition
    % Open part
       1 = E40 1 40
    ! ####################################################################################################
    INTERRUPT2 CALCUL
    ## This question e-mails the text of INTERRUPT3 to the respondent at the AINTERRUPT address
    % Question
       AINTERRUPT2 = email("info\@callweb.ca",$AINTERRUPT,"INTERRUPT3")
    % Note
    % Categories

    % Skips
    % Condition
    % Open part
       1 = C40 1 40
    ! ####################################################################################################
    INTERRUPT3 EMAIL
    ## Text of the e-mail sent out
    % Question
       Resuming your questionnaire
    % Note
       Please click the following link to resume your questionnaire:<P>
       http://{$contexte{host}}{$contexte{script}}?_proj={$_proj}&_lang={$_lang}&_telkey={$_telkey}
    % Categories
    % Skips
    % Condition
    % Open part
    ! ####################################################################################################
    INTERRUPT4 CALCUL
    ## Closes the browser window
    % Question
       dump = ferme_le_navigateur()
    % Note
    % Categories
    % Skips
    % Condition
    % Open part
    ! ####################################################################################################
    TERMINE BLANK
    ## This question ends the questionnaire.
    % Question
    % Note
    % Categories

    % Skips
    % Condition
    % Open part
    ! ####################################################################################################

Discussion

Sometimes, respondents want to stop filling out a questionnaire and resume later. This is easily achieved by re-using a link that was sent with an invitation to take part in the survey if access is password-protected (# Type enquete = 2). However, if access was open or if an access-code was provided upon entry, respondents are unlikely to have the information required to return.

In these circumstances, the Stop button can be displayed with a pound instruction like the following:

    # Bouton stop = oui,INTERRUPT

which activates the Stop button and instructs CallWeb to go directly to the INTERRUPT question once the button is clicked (clicking the Stop button also saves the data already provided on that page but does not validate them).

The interruption destination question can do anything. The following code shows how to request that an e-mail address be supplied and how to send a message containing a link back to the questionnaire — right where the interview left off.