PeterPanettone 139 Posted August 4 (edited) I have a very long HTML code text in the clipboard (<HTML>...</HTML>) without line-ends which I want to convert into a string constant in the Editor. If I use any of the GExperts string converters, I get the Compiler error message "Line too long". So how can I convert-split this very long clipboard string into concatenated strings of fixed maximal length suitable for a string constant, e.g.: const MyHTML = '<HTML> ...' + '...' + '...' + ... '...</HTML>'; Edited August 4 by PeterPanettone Share this post Link to post
Der schöne Günther 206 Posted August 4 This is exactly what the MultiPaste tool is for. You can find it in Delphi at Edit -> MultiPaste. Using the MultiPaste Tool - RAD Studio (embarcadero.com) (I think the picture they posted is incorrect, as it is not realated to MultiPaste at all) Share this post Link to post
Uwe Raabe 1360 Posted August 4 1 hour ago, Der schöne Günther said: This is exactly what the MultiPaste tool is for. Not quite. The MultiPaste expects some text containing multiple lines. Share this post Link to post
limelect 41 Posted August 4 Will my free tool will help you? https://limelect.com/downloads/add-characters-to-text-lines-on-large-scale/ Share this post Link to post
PeterPanettone 139 Posted August 4 Thanks for all the answers. I was hoping that an existing addon like GExperts or MMX would provide that feature. As it is very easy to write such a tool (and I am not a night worker), I will do it tomorrow. Share this post Link to post
David Heffernan 1761 Posted August 4 (edited) This is why programmers learn to use scripting languages Edited August 5 by David Heffernan Share this post Link to post
DiGi 10 Posted August 5 I just wonder how do you get that text in your clipboard in the first place. Copy from another application (not from file on disk / http URL)? Share this post Link to post
ertank 17 Posted August 5 10 hours ago, PeterPanettone said: Thanks for all the answers. I was hoping that an existing addon like GExperts or MMX would provide that feature. As it is very easy to write such a tool (and I am not a night worker), I will do it tomorrow. Another alternative might be to use a text editor that can format your HTML and add quotes (possibly with the help of regex) Notepad++ https://notepad-plus-plus.org/downloads/ CudaText https://cudatext.github.io TextEditorPro https://texteditor.pro SublimeText https://www.sublimetext.com Share this post Link to post
PeterPanettone 139 Posted August 5 (edited) Done: You can download it here: Edited August 5 by PeterPanettone Share this post Link to post