Trigger event only if text box has text entered
I have a text box on a slide that I want to make sure students fill out before they are allowed to continue with the rest of the course. The text is not to be graded, I just want to make sure they enter something first. I've tried several different things but I can't get it to work correctly.
First off, I created a variable for the text box. Then I created an advanced action with an 'If' statement to check for a value before 'Continuing'. This works in doing the validation. However, there's a small problem. If at first try I hit enter with an empty text box it doesn't 'Continue', which is what I want. But then it seems like no more attempts are being allowed because no matter what I enter in the text box it still doesn't 'Continue'. If at first try I enter something in the text box then it does 'Continue'. It seems like it just letting me make one attempt even though I have the 'Infinite Attemps' checkbox selected.
I also tried doing it with plain Javascript. I created an advanced action that triggers a script. Inside the script I check the value of the text box variable to make sure it's not empty. But then my problem is how do I programmatically trigger the slide's continue event. I tried creating a continue button and hiding it until the text box has been filled. But again, I don't know how to programmatically show it. I looked at the CSS and I can display it but the click event doesn't work.
I'm new to Captivate so it might be something simple that I'm missing.
Thanx
