User notes that they can print and email

Hi all. I built a course earlier this year that contains a "notes" function to allow users to take a moment to reflect and type their thoughts on certain questions. This is used in place of a typical multiple response/choice type question. Thought I'd share it here with you!

Here are the files:

Screenr Part 1: Demonstration -

Screenr Part 2: How It Was Built -

Storyline Source:

Published Output:



254 Replies
joanna miller

Hello, I have another question on the Notes element of this thread. I'd like to create a Notes panel that learners can show or hide throughout the training, using it to type in their notes as needed and emailing all their notes to them at the end.

I have the email piece down thanks to this thread.The issue I'm running into is that I can't figure out a way to allow learners to show the Notes panel whenever they want to.   I placed a Notes panel with a show/hide button on a Master Slide, but when I use that layout with multiple layers that show/hide one at a time as the learner clicks a series of buttons, the Notes panel disappears with the first button click, as does the Note panel button.

If you can figure out how to do this - or help me identify what I am doing wrong - I'd appreciate it!


Phil Mayor

You need a variable so you know if the notes panel is open and closed, e.g. NotesOpen

Set it to true whenever it is open and false when it is closed.

Now on each layer in your course add a trigger that shows your notes layer (I presume you are incrementing a variable, on condition NotesOpen is equal to true, ensure the the notes layer is set to not hide other layers.

Not sure why the notes panel button is hiding is that on a layer as well?

joanna miller

Hi Phil, many thanks for your suggestion!  I'm now closer to a solution but not quite there yet. Here's what I've done:

*Created a NotesOpen variable as you described
*Reconfigured the master so a button opens a notes layer and sets the NotesOpen variable to true, and sets the variable false when learner clicks the close button
*Set the notes layer not to hide other layers

Here's what happens now:

When I apply this layout to a slide with multiple layers that show/hide one at a time as the learner clicks a series of buttons, the Notes panel disappears with the first button click. Since the My Notes button still displays on the page, this isn't a dealbreaker, but it would be nice for learners for the open notes layer to stay open until they close it (rather than requiring them to keep clicking the My Notes button to re-open it when they are still interacting with the page).


joanna miller

I was eventually able to solve this and get the Notes layer to show continuously throughout a slide that contains button-activated show/hide layers. However, my solution isn't optimal because on pages with layers it requires me to uncheck "Hide other slide layers" in Slide Layer Properties to enable the Notes layer on the master slide to always display. I wasn't able to accomplish this using a variable alone.

Unfortunately I am unable to upload a slide to this forum, but I hope that with the info below you will be able to understand what I've done and possibly suggest some way to simplify it by adding another trigger or variable.

Key variable: ShowNotes which shows or hides the notes layer that lives on the Master Slide (Show layer Notes if ShowNotes=true)
Master Slide:
On content slides:
Base layer - contains hotspot over a button on the Master Slide that toggles variable ShowNotes when user clicks; for each button that shows a layer on click, hides all other layers on the page (except Notes).

Thanks, as always, for the encouragement and assistance from this forum!




ronel taruc

Bruce - Yes, you can enter lengthy text and it will be captured in its entirety in the email body, printed version too.

For some reason when typing in lengthy text not all texts show in the email body :/ -- I wonder what's wrong. I also noticed that breaks aren't reflected either. The paragraphs just connect to each other in one line even though in the original entry they are separated. Thoughts?

ronel taruc

I just used the same story file Stephanie provided. In the published file, here's the text I typed in:

Activity: Delivering Coaching Feedback
Get managers consistently & confidently including right elements in a coaching conversation by giving a simple tool and practicing. Get this to be second nature…

Increase manager confidence and speed in delivering focused feedback using the COACH model to structure the coaching conversation

Activity: Coaching Scenarios & Practice
If you do not have recorded calls, use these scenarios to practice the coaching delivery on the previous page.

My text entry

Then when i click on the email button, here's what's shown:

Email body

Thanks guys for helping.


ronel taruc

Thank you James! That surely solved the issue why not all text appear on the email bocdy. There's one thing still bothering me though. The text seems to ignore line breaks. Even though there are 3 paragraphs in my sample - they were all interpreted as one continuous paragraph. Is there a work around for this? Thanks!


onEnterFrame (James Kingsley)

Hmm I don't recall if SL strips the line breaks out when it saves the variable. If not then they are probably in there as '\n' which will not be displayed in HTML. (Your email editor probably defaults to HTML). So you will need to find all instances of '\n' and replace them with '<br/>'. 

It would be easier if your were using a library like jQuery but it can be done with generic JS something like this:

your_string.replaceAll(new RegExp('\n', 'g'), '<br/>');

We are using the standard JS replaceAll function but have to use a Regular Expression to match the pattern of the unseen ASCII line breaks.

Your milage may vary on the code above as I didn't test it before posting it here.... 


It really isn't that strange. The printable page is being rendered through HTML. In HTML, some characters are 'Reserved'. For example the less than (<) & greater than (>) signs are used to open and close tags and so the browser might be confused by their use as pure text.   Therefore, special characters have an assigned 'entity' that you can use to display them. Character entities look like this:
&entity_name; or &#entity_number;

Note that character entities always start with the ampersand (&) which makes it one of these special characters that html treats differently.  The correct way to display an ampersand in html is to use &amp; or &#38;

Line breaks are similar.  In HTML they require a specific element which is written as: <br>.

StoryLine, on the other hand, is recording your actual text entry and holding it in a variable (that acts like a container).  It has captured and recorded '&' as '&' and not as '&amp'. When you try to take text stored this way in it's native format and render it in html, it is not unlike trying to put a square peg in a round hole. You  need to make some changes first.

Sometimes, it is easier to change your methodology. For example, instruct users to add their notes 1 paragraph at a time and capture each paragraph in it's own variable. Or run JS  'when the user presses a key (enter) to capture what they have input so far and add the appropriate  html line break characters to a different variable to be used when printing.


If your email is not html based, you would need to convert the break to the following hexadecimal equivalent of a carriage return that the computer would then recognize: %0d%0A

So using James suggestion above, try something like the following JS:
your_string.replaceAll(new RegExp('\n', 'g'), '%0d%0A');

You can learn more about the 0d0a pair of characters as the signal for the end of one line and the beginning of another one HERE.

And to steal James' line.... Your mileage may vary on the code above as I didn't test it before posting it here....

Charlotte Laird

I love these posts, especially about Javascript as I find it so dynamic.

I'm still fresh to Javascript and have been using it for a note taking portal for users to take notes and email them upon completion. I've been asked if there is a way to have the user click on a specific sentence on a page in SL and have the text copy to the note taking portal for them to add / remove text as pleased and then email themselves upon completion.

Is anyone aware of how to do this or if it's possible?

Matthew Bibby

Yes, that is possible Troy! You'd need to add a trigger to each sentence with JS that would concatenate that text with the text that is already stored in the notes variable.It'd

It'd be time-consuming to set up and annoying if you ever needed to update the text in the course... but definitely possible.