by Lori Smith
If you have played around with Captivate 4's Advanced Actions features, you have surely discovered that you can add two items together such as myCount := myCount + 1 or myBossSalary := mySalary + mikeSalary.
But, did you know that you can also add words together (concatenate)? You can certainly have an assignment statement of the type: fullName := firstName + lastName.
If your student inputs Biff and Bifferson to firstName and lastName in a couple of text entry boxes, your fullName will end up being the sum of those two. Cool, yes? Well, only if you like your fullName to be displayed as BiffBifferson. Gee, that's a bit annoying… it's one long name and hard to read. You might try to add a space in the middle by doing something like:
fullName = firstName + <space>
fullName = fullName + lastName.
But I can tell you right now, that it won't work. Try adding slashes, single or double quotes… still a no go.
I have a little trick I call the Spacer object. The Spacer object is a Text Entry Box that contains a space character.
First, create a variable named spacer (via Project > Actions > Variables).

Next, create a text entry box on the first slide of your project and stick it up in a corner so no one can click it or fill it in by accident. Then, set the initial value to a blank space and check the retain value field.

Associate the variable spacer with the text entry box.

On the Options tab, set the rest of the text entry box's settings as shown below:

Now that you have a space handy, you can go back to your action and enter the following:
fullName := fullName + lastName
The result when fullName is displayed via a Text Caption will appropriately be "Biff Bifferson."
This is just a little something I like to have handy when I'm working with advanced actions in Captivate. Like this little tip? Want to learn more about Captivate's Advanced Actions? Join me online as I lead you through a 3-hour course focusing on Captivate's Advanced Actions.
***
***
Worried about your class canceling? You'll be happy to hear that IconLogic never, ever cancels classes (even if there's just one student registered).