I've followed the steps to create the widget. When the trigger to execute the javascript completes, it pulls in the column name fine, but the variable data doesn't get pulled in. It just shows the variable name.
So for example I create a variable called TextTest
The javascript code I add into the trigger is the following: SheetsSet('Text', 'TextTest');
The column name in the google sheet shows Text But the data below the column name shows TextTest
Any thoughts welcome.
Reply
Posted on 3/6/2022
Please type your reply.
@support
Hello. Please make sure you followed step 1 of the instructions:
Open Storyline and create a blank text variable stencilsheetstoken.
Reply
Posted on 3/6/2022
@jackwaller
Hi John,
Yeah I did that. First step. It's in the variable list. It's a blank text variable
Reply
Posted on 3/6/2022
@support
Jack, if you want to upload your file with the triggers and post a link here, I'll take a look to see what's going on. Thank you!
Reply
Posted on 3/6/2022
@jackwaller
Hi John, sure that would be great.
Link to file - https://we.tl/t-YNQ2V5dFd0 Link to google sheet - https://docs.google.com/spreadsheets/d/16RRC_ID7if6ya3RyiU09XY8uWxZMm2_bCBr2wl1m1s8/edit?usp=sharing
Thanks,
Jack
Reply
Posted on 3/6/2022
@support
Ok, the widget works as expected. It's your trigger on the second slide that you should look at. Here are the instruction for using SheetsSet:
Replace column header with a header of your choice. Replace value with the data you wish to save. When you call SheetsSet('Text', 'TextTest'); you're saying "write the exact statement 'TextTest' in the column 'Text.'
If you wanted to send the value of the variable TextText, you would do something like this:
var player = GetPlayer();
SheetsSet('Text', player.GetVar('TextTest'));
Reply
Posted on 3/6/2022
@jackwaller
Hi John, thanks for your reply.
I wouldn't say the widget works as expected. It just sends the name of a variable, not the data from the variable itself.
I've pasted the code that you suggested, but it still doesn't work. I can see that you got it to work once from the google sheet. Would you be able to send the file back again so I can see what you've done to get it to work?
Hi John - your advice above is invaluable & I've got my variable reporting to the right columns in the spreadsheet. However, each variable is making a new line when I need three variables in three columns in the same line. (First name, last name, email). What do I do with the code to make that happen? Many thanks
Jay
Reply
Posted on 3/6/2022
@jackwaller
That's great, thanks John. I've got that working.
I would suggest adding the additional step to pull the variable data through to the sheets into the instructions. That would then mirror the setup you provided in the demo.
Many thanks for your help with this.
Jack
Reply
Posted on 3/6/2022
@jackwaller
That's great, thanks John. I've got that working.
I would suggest adding the additional step to pull the variable data through to the sheets into the instructions. That would then mirror the setup you provided in the demo.
Many thanks for your help with this.
Jack
Reply
Posted on 3/6/2022
@pcarra
hello, I have exactly the same trouble.
The instructions do NOT say how to send to the spreadsheet the value of the variable and not a simple text (that is not useful).
May I have the working sample project? The download link above in this post is expired, unfortunately.
I suggest also to update the instructins to avoid teh same trouble to other users.
Thank you very much.
Piero
Reply
Posted on 3/6/2022
@pcarra
hello, I have exactly the same trouble.
The instructions do NOT say how to send to the spreadsheet the value of the variable and not a simple text (that is not useful).
May I have the working sample project? The download link above in this post is expired, unfortunately.
I suggest also to update the instructins to avoid teh same trouble to other users.
Thank you very much.
Piero
Reply
Posted on 3/6/2022
@sandrade
I am also having trouble with the widget. I can make it reference a string like ‘variable’ but am unable to get it to pull the value for the variable. I tried SheetsSet(‘column’, info) but it does not do anything. If I put SheetsSet(‘Column’,’info’) it returns the word info in the sheet.
Reply
Posted on 3/6/2022
@support
I think this is what you're looking for:
var player = GetPlayer(); SheetsSet(‘column’, player.GetVar('info'));
Reply
Posted on 3/6/2022
@aleko21
Dear support, we are experiencing the same problem! We have a very complex storyline project but we are trying your widget with a very easy project.
Even if we set a trigger with var player = GetPlayer(); SheetsSet(‘column’, player.GetVar('var1'));
The sheet is not written by the widget with our variable.
I attach the story file: https://we.tl/t-nTXxCN3BOv Thank you in advance.
Reply
Posted on 3/6/2022
@support
Just by looking at the posting above, I can tell that this javascript trigger is invalid because 'column' is enclosed in apostrophes instead of single quotes. This is not a valid javascript syntaxis. There can be, of course, other issues with the module, but this would be a good starting point for troubleshooting.
Hello friends. Can I ask something about writing code?
So, I've written a code. However, if you look at the results, there are problems, namely there are empty boxes that do not match the lines. Is there something wrong with writing my code? Thank You