Use hidden text fields?
Create: Using the addField method, then setting the other properties, such as display, as you wish.
Read: Just like any other field, using the getField method and the value property. It doesn't matter to the script if the field is hidden. It can be accessed just like any other field.
Writing (for some reason visible is 0 and hidden is 1 for display)
oField = oJSpdf.addField($name, "text", 0, $a)
oField.value = "this is a string"
oField.display = 1
It'd be cool if people added small examples, so when someone later on comes searching and finds your post you help them out as well
What language are you using to write this code? You don't need to place dollar signs before variable-names in JS, you know...
There are plenty of examples in the JS for Acrobat API Reference, which can be found here:
I thought I removed all of them, derp