Forum Discussion

AnneKathrineSko's avatar
AnneKathrineSko
Community Member
3 years ago

Javascript for download of print screen of slide

Hi All!

I have a course where the learner type some text in a text input field and then need a screenshot to share with peers. I have used the new Print-trigger which is great, but I would prefer it to be a download-trigger in this case. I know that it is possible to just print as PDF in the printer view, but some of my learners tech knowledge in that area is... well... not quite up to date. Maybe someone had the same issue and found a solution in form of a javascript or some other way? The download output could be pdf or png. 

  • Hi Anne, this is quite a complex thing to achieve using JavaScript. You would need a JavaScript developer to help you do this as it would require the integration of a JavaScript library such as jsPDF (https://artskydj.github.io/jsPDF/docs/jsPDF.html) and then the developer would need to grab the data from Storyline and use the jsPDF library to create the PDF for download.

    Just letting you know it is not something that could be undertaken by somebody without JavaScript programming knowledge.

  • Hi Sam

    Thank you for replying and enlightening me on the topic. I feared that there was no easy way here - and my javascript skills are pretty basic. I'll work on with the print-trigger and guide my learners. 

    Thanks again!