Exporting variables to .txt file.... PLEASE HELP!!! URGENT!!!
May 08, 2016
Hello,
I have been trying to get Storyline 2 to export variables to a .txt file. I am working on a project for a client who does not have an LMS, or access to the internet and I need to provide them with a way to export variables for completion as they will be using this data to award a statement of attainment. I have tried everything for it to work, here is my code:
var fso = new ActiveXObject("Scripting.FileSystemObject");
var s = fso.OpenTextFile("D:\\Test.txt", 8, true, 0);
var player = GetPlayer();
var Firstname = player.GetVar("FirstName");
var Surname = player.GetVar("Surname");
s.WriteLine("Firstname: " + firstname);
s.WriteLine("Surname: " + Surname);
s.WriteLine("==========");
s.Close();
I have tried writing to the C:// as well with no luck. I have tried publishing many different ways as well, to Web, CD, etc.
If anyone can suggest how I may be able to make this work I would be so appreciative!!
Thanks
1 Reply
Hi Cherie,
The Javascript elements are not something that our team can assist with, but I did want to share this article of best practices as a reference.
This discussion is closed. You can start a new discussion or contact Articulate Support.