Copy link to clipboard
Copied
In a responsive project, I have a user complete a number of textboxes. Then, I use a submit button with an Advanced Action that tests the responses. This works great if the use selects the correct case. I don't see a way in which I can turn this off in the Advanced Actions. Thoughts, or is there a better way?
Regards,
Dave
Copy link to clipboard
Copied
Maybe you'll have to write some JS. The only place I'm aware of where you can turn off cases sensitivity is when validating an individual TEB. With JS functions you can have a workaround.
Copy link to clipboard
Copied
Any thoughts on how I can apply that JS... I tried using the Execute Java script on focus. It doesn't appear to work....
Cluster = Cluster.toLowerCase();
Cluster is the variable that I used the user input to.
Copy link to clipboard
Copied
It will not be that simple. I am not a JS expert. Several functions are available in the common JS API. Have a look at this document:
Learn about the Common JavaScript interface for Adobe Captivate
Copy link to clipboard
Copied
Thanks for the tip, Lilibiri - It took a little bit of testing by trial and error, but I created the solution. Just thought I would pass this on to any others on the forum that might be looking to do the same operation. I just wish there was a good course or book that covers the use of JavaScript in Captivate (other than document that you mentioned... there needs to be more examples in there).
So, here is the Javascript solution that I applied to the option when focus is lost.... "Cluster" is the variable that is capktured by the user input.
var x = window.cpAPIInterface.getVariableValue("Cluster");
var str = x.toLowerCase();
window.cpAPIInterface.setVariableValue("Cluster", str);
Thanks again.
Copy link to clipboard
Copied
Sure, was very busy yesterday....sorry to have left you without a real answer?
Copy link to clipboard
Copied
no worries, Lilibiri... This area of javascript usage is Captivate is an area that I really wish that Adobe would address with some good training and documentation. The only real documentation available appears to be the one that was sited earlier, which is quite weak and lacking of real examples. Unfortunately, users are left with little to go on. A nice Javascripting in Captivate course would be great... my suggestion.
Copy link to clipboard
Copied
There was a great course by Jim Leichliter, but he left eLearning for a couple of years, now he is back.
I don't know if this is as urgent as other courses because only a small minority of users do indeed implement JS in their courses. Same for me, when I cannot solve it with advanced/shared actions, will use JS. Reason: for clients it is much easier to track advanced actions than JS. Even the present Help documentation has not been updated, do not expect that Adobe will address this at all.