PS: Read Only Table To TXT

less than 1 minute read


So the other day I was going through a web GUI for our Exchange and needed to edit the list, but the form was read only. No problem => use Powershell to get it to a TXT I can manipulate!

To Resolve:

  1. Uggh, can’t select the cells. Can’t copy/paste or anything!
    • ps-read-only-table-to-txt-1
  2. Wait a minute, Ctrl+U => Select source
    • ps-read-only-table-to-txt-2
  3. Paste that into a text file. Now just run my Get-ExtractedEmailAddresses script so I can get only the emails from this block of HTML. Result:
    • ps-read-only-table-to-txt-3
  4. But there is double of everything! No problem, just open up Powershell and run:

    Gc .\extracted.txt | sort -unique | out-file .\sorted.txt
  5. Done!
    • ps-read-only-table-to-txt-4