Hello,
the script/macro “Reformat: break line at n-chars (VBScript)” still works in EmEditor v25.1.4
Only the forum software had added additional line breaks which make the macro not working.
So, after copying the code to a local file, remove all empty lines.
(it’s okay to keep that few empty line which have white space in it,
only that completely empty lines, added by the forum (for me that are the grey one) have to go)
To do that ,in EmEditor, have the file with that above code open,
right click and choose > “Convert Selection > Remove Empty Lines”.
Also the both “Script Directives”:
#title = Reformat
#tooltip = Reformat: break line at n-chars
must be not indented but on Pos. 1
and also on line one and two without empty lines above .
Furthermore, my step “4.) press F4” is true only if you had assign an keyboard shortcut to that macro.
On default, just use the menu “Macros > Run somename.vbee Ctrl+Shift+P”
Also:
1.) Save the code between 8< and >8 -lines as text file “somename.vbee” in EmEditor folder
1b.) Remove the superfluous empty lines
1c.) Adjust the position of the #ScriptDirectives
2.) use Menu “Macros > Select…” and choose this somename.vbee as current default macro
3.) open an test file (try first on an test document!) and select some long lines
4.) press “Ctrl+Shift+P” to run the macro, you will be prompted to enter the max chars to break the lines
Your done.
.