Explore the community Forums Lectora Lectora Questions & Answers Simulate Text Entry? Reply To: Simulate Text Entry?

#418887 Score: 2
Profile photo of Stan Miller
Stan Miller
Member
beginner
intermediate
LUC16 Attendee
wise owl
contributor
curious george
friend finder
LUC17 Attendee
38 pts
@smiller7502

@adam Cain’s answer is excellent for the specific case. However, if the correct entry contains more than one letter and case doesn’t matter, testing all the possible conditions can quickly become tedious.  For longer text entries, consider first a Run JavaScript action to run the following script:

var userEntry = VarYourTextBoxNameHere.value;
var lc = userEntry.toLowerCase();
VarYourTextBoxNameHere.set(lc);

You can then run just one conditional test to see if the lowercased version of whatever the user typed matches what you need it to match.

This post has received 2 votes up.