autohotkey - RegEx: find and replace EOL between quotes -


in multi-line string this:

she loves [mono],"past masters, vol. 1",4,"she loves you, yeah, yeah, yeah loves you, yeah, yeah, yeah loves you, yeah, yeah, yeah, yeah" 8 days week,beatles sale,8,"eight days week love you. 8 days week not enough show care." 

i want replace eol (\r\n) between quotes replacement character "¶" (ascii code 182) make string single-line.

the result be:

she loves [mono],"past masters, vol. 1",4,"she loves you, yeah, yeah, yeah¶she loves you, yeah, yeah, yeah¶she loves you, yeah, yeah, yeah, yeah" 8 days week,beatles sale,8,"eight days week¶i love you.¶eight days week¶is not enough show care." 

i tried various regex related solutions found on stackoverflow not able adapt them want.

i use regex expression in ahk function:

regexreplace(haystack, needleregex [, replacement = "", outputvarcount = "", limit = -1, startingposition = 1])  regexreplace(mytext, needleregex???, "¶") 

any appreciated.

you can parse string , operate on way maybe?

str =  ( loves [mono],"past masters, vol. 1",4,"she loves you, yeah, yeah, yeah loves you, yeah, yeah, yeah loves you, yeah, yeah, yeah, yeah" 8 days week,beatles sale,8,"eight days week love you. 8 days week not enough show care." ) outstr := "" loop, parse, str, `" {     field := a_loopfield     stringreplace, field, field, `r,,     stringreplace, field, field, `n, ¶,     outstr .= field } msgbox % outstr exitapp 

Comments

Popular posts from this blog

networking - Vagrant-provisioned VirtualBox VM is not reachable from Ubuntu host -

c# - ASP.NET Core - There is already an object named 'AspNetRoles' in the database -

ruby on rails - ArgumentError: Missing host to link to! Please provide the :host parameter, set default_url_options[:host], or set :only_path to true -