Animate CC Captivate HTML5 Intergration
Hi all
I am needing a little help, I'm not fantastic with Javascript, but i would not consider myself a noob anymore, I have been creating Html5 canvas pages in Animate CC and inserting them into captivate as web objects, i have been controlling slide movements via code in animate CC applied to Buttons such as -
this.Previous.addEventListener("mousedown", fl_MouseClickHandler_Previous.bind(this));
function fl_MouseClickHandler_Previous()
{
window.parent.cpAPIInterface.previous();
}
This all works fine, but what i am trying to do now is confusing me, I have used the UI Components in Animate CC to produce a combo box and a button, on the combo box i have applied the following code snippet
if(!this.ComboBox_change_cbk) {
function ComboBox_change(evt) {
// Start your custom code
console.log(evt.target.value);
// End your custom code
}
$("#dom_overlay_container").on("change", "#ComboBox", ComboBox_change.bind(this));
this.ComboBox_change_cbk = true;
}
this works fine and displays a value in console.log, now what i am trying to do is have the button submit the value that gets set in the console.log to a variable in captivate, this is the code i have written but it did not work
this.movieClip_2.addEventListener("mousedown", fl_MouseClickHandler.bind(this));
function fl_MouseClickHandler()
{
window.parent.cpAPIInterface.SetVariableValue("cpQuizInfoStudentID", console.log($("#ComboBox").val()));
}
can anybody help?
Sitting patiently
Craig
