Labels that have an apostrophe in them are causing problems
« Back to message list
I am graphing scores for individuals and use their names in the labels. The following is an example of how I am setting
the labels:
.Set('labels', ['John Smith', 'John O'Grady', 'Simon O'Neil', 'Alan Watson', 'Kim Jackson'])
The apostrophes in O'Grady and O'Neil are obviously causing a problem. I should very much appreciate your advice whether there is a solution to this problem other than to remove the apostrophes in the name and merely input OGrady and ONeil.
Many thanks for a great tool and for your assistance.
Posted by Richard on 24th February 2014.Set('labels', ['John Smith', 'John O'Grady', 'Simon O'Neil', 'Alan Watson', 'Kim Jackson'])
The apostrophes in O'Grady and O'Neil are obviously causing a problem. I should very much appreciate your advice whether there is a solution to this problem other than to remove the apostrophes in the name and merely input OGrady and ONeil.
Many thanks for a great tool and for your assistance.
Hi there,
Use Double quotes to surround them:
.Set('labels', ["John Smith", "John O'Grady", "Simon O'Neil", "Alan Watson", "Kim Jackson"])
Richard
Use Double quotes to surround them:
.Set('labels', ["John Smith", "John O'Grady", "Simon O'Neil", "Alan Watson", "Kim Jackson"])
Richard
Add a reply
« Back to message list