I understand why this will not work directly from the Find/Replace in the SE. That function does not know how to repace a semiColon with an actual return char.
But a button somewhere, or a plug-in if that is more convenient, with a very simple handler can. (Pseudo) get the script of the objectOfInterest replace “;” with return in it set the script of the objectOfInterest to it Done. Craig > On Apr 6, 2021, at 5:47 AM, John Balgenorth via use-livecode > <[email protected]> wrote: > > I haven’t been following this subject that close so I could be missing > completely with my answer, but when writing code in C or C++ the > /n is simply a / and n characters not a carriage return. The \n is > used for a new line which is a carriage return. If I am missing the > point just ignore the post. > > Forward slash n (/n) does not make a new line. > Back slash n (\n) does make a new line. > > JB > >> On Apr 5, 2021, at 10:28 PM, Sean Cole (Pi) via use-livecode >> <[email protected]> wrote: >> >> Bob, Regex only appears to operate on the read of the text, so >> ; >> in the *find* field will locate all of the places a semicolon is found, but >> putting >> /n >> into the *replace* field will not replace the ; with a cr >> >> Brian, The project is huge and I don't yet have the time to invest in >> porting it all to github just yet. As it is I have created my own simple >> regex text operator that I copy/paste the script into. >> >> https://www.dropbox.com/s/glq6pco70d3zgt3/Screenshot%202021-04-06%20at%2006.21.22.png?dl=0 >> >> Richard, I've tried in the Find, Find and replace of the script editor and >> the Find/Replace from the main menu. I can't seem to place a carriage >> return (or line feed or whatever) into the replacement field. This is what >> I am trying to achieve. Replace ";" with "cr" in myScript. I can do it in >> code, but not from the find/replace windows. :( >> >> Sean >> _______________________________________________ >> use-livecode mailing list >> [email protected] >> Please visit this url to subscribe, unsubscribe and manage your subscription >> preferences: >> http://lists.runrev.com/mailman/listinfo/use-livecode > > _______________________________________________ > use-livecode mailing list > [email protected] > Please visit this url to subscribe, unsubscribe and manage your subscription > preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode _______________________________________________ use-livecode mailing list [email protected] Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
