The Response variable is a local text variable set to the user's Response as follows:
Example: A user dials in to the Call Tree created In the Quick-Start Tutorial example. The user presses 1 at the Answer_Phone Node's prompt to leave a message for Bill. In this case, at the Answer_Phone Node, the Response variable will equal "1".
Example: A user dials in to the Call Tree created In the Quick-Start Tutorial example. The user presses 2 at the Answer_Phone Node's prompt to leave a message for Mary. The Call continues to the Check_Response Node, where there is no question. There are two responses defined on the Responses tab at the Check_Response Node: "1" and "2". Since the user's response from the previous Node (Answer_Phone) matched a response defined at the Check_Response Node, the Response variable will equal "2" (the user's response at the previous Node) at the Check_Response Node during this call.
Example: A user dials in to the Call Tree created In the Quick-Start Tutorial example. The user presses 3 at the Answer_Phone Node's prompt by accident. The Call continues to the Check_Response Node, where there is no question. There are two responses defined on the Responses tab at the Check_Response Node: "1" and "2". Since the user's response from the previous Node (Answer_Phone) does not match a response defined at the Check_Response Node, the Response variable will be blank at the Check_Response Node during this call.
Experimenting with the Response Variable
It's easy to experiment with the Response variable to see how it changes during a Call Tree. Simply insert the line:
MsgBox "The Response variable = " & Response
at the top of any VBScript Macro. Try it! Modify the Quick-Start Tutorial example to show the Response variable at the Check_Response Node as follows:
Open the Quick-Start Tutorial Answering Machine Example Call Tree file in the Examples folder.
Make a copy of the Call Tree if there are any doubts about being able to restore the Call Tree to normal function later. For instructions on copying Call Trees, refer to Make a Copy of a Call Tree.
Click on the Check_Response Node.
When the Edit Node window appears, click on the VBScript Macro tab.
Insert a blank line at the top of the Macro by pressing ENTER.
On the blank line, type:
MsgBox "The Response variable = " & Response
Press the Click here when finished button.
Simulate some calls by selecting Phone Calls ... Simulate Call from the menu bar. Be sure to vary the response given at the first prompt to see how the Response variable changes.