First, you must create two additional User Variables in the takeTheTrain.cptx project by using the following steps:
- Return to the Chapter14/takeTheTrain.cptx file.
- Use the Project | Variables menu item to open the Variables dialog.
- Click the Add New button to create a new User Variable.
- Name the variable v_randomSuccess and leave the value field empty.
- Click the Save button to save the new variable.
- Repeat the same procedure to create the v_randomFailure variable.
- Close the Variable dialog when done.
You now have two additional variables in your project. These two variables will be used to store the random success and failure messages that will be generated by the JavaScript function. The next step of this process is to create the necessary pools of messages using JavaScript arrays.
JavaScript is case-sensitive
When performing this exercise, be aware that JavaScript is case-sensitive. Make sure that you create variables that have the exact...
When performing this exercise, be aware that JavaScript is case-sensitive. Make sure that you create variables that have the exact...