User Tools

Site Tools


powershell

Links for extracting text between two markers in one file:

https://stackoverflow.com/questions/26185578/windows-powershell-extract-multiline-text-between-two-words-from-a-text-file

From there this looks like an intersting start

$str = Get-Content .\GoPaperLessTShirts_113mails_may2014.txt | out-string $start = $str.IndexOf(“Information Submitted:”)+1 $end = $str.IndexOf(“From:”,$start) $length = $end - $start $str.Substring($start,$length)

https://stackoverflow.com/questions/49001716/extract-lines-between-two-tags

https://social.technet.microsoft.com/Forums/en-US/b04b6a9f-2a86-49f9-8fec-87197638202f/powershell-extract-over-multiple-lines?forum=winserverpowershell

powershell.txt · Last modified: 2018/08/03 11:59 by zeppo