Hi,
Nice work! I'm glad the code is getting some use!

I know very little about HTML and even less about JAVA Script (which I suspect is what Document.Write() is?

However, doing document.write(AN2) where I'm guessing AN2 is a variable in you PBP (Proton) program probably isn't working the way you expect. For it to work the way you've coded it the PutStringInTxBuffer routine would need to be able to decode and understand Java Script, find AN2 and put its content, as a string into the buffer - that's obviously NOT how it works or is intended to work.

Again, I'm very green on this HTML and JAVA stuff so I may be wrong but that's how I think it works.

In PBP, to load a "value" from a variable into an array as a string you could use ArrayWrite, I'm not sure how to do that in Proton but I'm sure there's some ToStr or whatever.

Does that make sense?

/Henrik.