I'll try and write a generic dialog handler script for you, it won't be today
though - I've just spent too much work time today doing PSPad scripts!
With regards to the ' thing - just escape all the single quotes in the HTA with
backslashes. Basically load up your HTA in PSPad, then run the following s/r's:
(1) : Search ['] replace with [\'] [not regexp]
(2) : Search [^(.*)$] replace with [ts.WriteLine('$1');] [regexp]
(The square brackets are NOT part of the expressions - they're just there to
delineate them.)
Then copy/paste into the .js, and Bob's your uncle!
--
<http://forum.pspad.com/read.php?2,40610,40650>
PSPad freeware editor http://www.pspad.com