Find specific line in document

Using your example data, I found that there was a SPACE after "OUT:".
So the RegEx Look Behind requires this space:
(?<=OUT: \n)(^.+?) *$

<img src="/uploads/default/original/2X/9/9fa034801953dfe7d1745afcb7087c7530a06e23.gif" width="70" height="17"> 2017-04-13 21:52 CT

See final macro posted at:
[MACRO:   Parse String from File into Multiple Variables @RegEx @Example](https://forum.keyboardmaestro.com/t/parse-string-from-file-into-multiple-variables-regex-example/6810)

2017-04-12 19:33 CT

  • I figured out another RegEx pattern that does NOT depend on having a SPACE after the "OUT:". It works with and without a SPACE. Ver 2.0 uploaded with this fix.

See if this will help get you started. Please let us know if this works for you.

##example Results

NOTICE: This is just an example.
It has had very limited testing and most likely will require further testing and changes by you BEFORE you use it in production environment.

##Macro Library   @RegEx Parse String into Multiple Variables @Example


####DOWNLOAD:
<a class="attachment" href="/uploads/default/original/2X/9/9a07aef1e524b192fd14b522101961097c586f72.kmmacros">@RegEx Parse String into Multiple Variables @Example.kmmacros</a> (6.6 KB)

---

###ReleaseNotes

TBD

---

<img src="/uploads/default/original/2X/9/99049fd2b6b98ac9d27fc8d3a396e55cced71048.png" width="450">
1 Like