vbr: -------------------------------------------------------------------------------- Hi, you are welcome, I am glad, it helped.; I just tried to write a javascript sorting function for this; you may try it on your input files and probably modify it to work as needed, also for possible cornercases. --------------------------------------------------------------------------------
Oh wow, that gives me a headstart of at least a week :-D Thank you SO MUCH! vbr: -------------------------------------------------------------------------------- The text is replaced for the original editor content, you may use copies, if needed. -------------------------------------------------------------------------------- That would be no problem. vbr: -------------------------------------------------------------------------------- just save the following e.g. as a js file in ...\PSPad\script\JScript\my_pspad_javascripts.js ... After calling Script: Reload script (or on a fresh start of PSPad) this function should be available via script-menu or directly with the shortcuts set in the Init() function (this must not be taken by any other function etc.) -------------------------------------------------------------------------------- Thank you again - really, having such an example works much (much, much :-D) better for me than digging through info and piecing together what I don't know. :) vbr: -------------------------------------------------------------------------------- Please test it to match all your requirements -especially the content of the original data - the regex should match whole lines, you are interested in. There must not be any data in the format used for intermediate numbering, i.e. __somenumber__ ; otherwise the sorting might break and the text could be corrupted.-------------------------------------------------------------------------------- If I understand the JS correctly, then the first replacement is only done on lines that contain '<Meta name="' - this would be safe on the whole file, it is guaranteed for all of *these* lines that do not (originally) contain anything of the form __somenumber__. But I'm not sure about the next two replacements. I will do tests later. vbr: -------------------------------------------------------------------------------- Another limitation of the current PSPad is the scripting support for unicode characters beyond the basic set Win-12... . If such characters appear in the source, they would be removed with this script.-------------------------------------------------------------------------------- There are about 40 "Meta" lines, some values contain text which can contain German umlauts (I didn't use these lines here because they may be not privacy-safe). But it looks like the German umlauts are contained in the Win-1254 code page (viz https://msdn.microsoft.com/de-de/goglobal/cc305147 ) and the Win-1252 code page. Thanks for mentioning it anyway, I was not aware of that. vbr: -------------------------------------------------------------------------------- hth, vbr -------------------------------------------------------------------------------- It does help, very much, indeed! :) I'll do some real tests in a few hours, after getting some other work done. Just wanted to tell you that I have seen it already and had a first look with my brain switched on. :) -- <http://forum.pspad.com/read.php?2,66273,66291> PSPad freeware editor http://www.pspad.com
