Problem with the variable wich doesn't appear.

Apr 18, 2014

In storyline, I try to add the value of a variable in a field (Short Answer survey question). But my problem is that I don't find the variable in Value List. But the variable exists when I click on X icon.

10 Replies
frederic regis

frederic rt

frederic regis said:

Thanks. It's a Numeric Variable. So have you got a solution for my problem.


frederic regis said:

Thanks. It's a Numeric Variable. So have you got a solution for my problem.


frederic regis said:

Thanks. It's a Numeric Variable. So have you got a solution for my problem.


frederic regis said:

Thanks. It's a Numeric Variable. So have you got a solution for my problem.


frederic regis said:

Thanks. It's a Numeric Variable. So have you got a solution for my problem.


frederic regis said:

Thanks. It's a Numeric Variable. So have you got a solution for my problem.


egis
said:

Thanks. It's a Numeric Variable. So have you got a solution for my problem.

frederic regis said:

Thanks. It's a Numeric Variable. So have you got a solution for my problem.

Steve Flowers

You could convert the value using a JavaScript trigger to concatenate the values. But you can't combine one variable type to another variable type using the trigger interface. The JS below in a JS trigger would grab the text field variable and the number variable, then combine them and send it back into the text variable. Only caution here is this will permanently alter your text field variable. So repeatedly hitting the even that fires the trigger will result in adding the number again.

var player=GetPlayer();

var oBase=player.GetVar("firstPartText");

var oNumber=player.GetVar("secondPartNumber");

player.SetVar("firstPartText",oBase+" "+oNumber);

Phil Mayor

Ashley Terwilliger said:

Hi Frederic,

The value of a numeric variable isn't included in a a quiz results or reported to your LMS, and the only method to report the value of a variable to an LMS is detailed here, but this wouldn't work with a numeric variable. 


t needs to be a graded or survey question and needs to be assigned to your results slide

frederic regis

Thanks, But when I try to add the js trigger and I publish it on Storylineonline nothing happens... I've added the accurated variables...

 

 

 

Steve Flowers said:

You could convert the value using a JavaScript trigger to concatenate the values. But you can't combine one variable type to another variable type using the trigger interface. The JS below in a JS trigger would grab the text field variable and the number variable, then combine them and send it back into the text variable. Only caution here is this will permanently alter your text field variable. So repeatedly hitting the even that fires the trigger will result in adding the number again.

var player=GetPlayer();

var oBase=player.GetVar("firstPartText");

var oNumber=player.GetVar("secondPartNumber");

player.SetVar("firstPartText",oBase+" "+oNumber);

Steve Flowers said:

You could convert the value using a JavaScript trigger to concatenate the values. But you can't combine one variable type to another variable type using the trigger interface. The JS below in a JS trigger would grab the text field variable and the number variable, then combine them and send it back into the text variable. Only caution here is this will permanently alter your text field variable. So repeatedly hitting the even that fires the trigger will result in adding the number again.

var player=GetPlayer();

var oBase=player.GetVar("firstPartText");

var oNumber=player.GetVar("secondPartNumber");

player.SetVar("firstPartText",oBase+" "+oNumber);

This discussion is closed. You can start a new discussion or contact Articulate Support.