Created
January 15, 2014 14:58
-
-
Save tormodfj/8437770 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function Get-PdfFormData | |
| { | |
| param($file) | |
| Add-Type -Path 'iTextSharp.dll' | |
| $fileInfo = Get-ChildItem $file | |
| $doc = New-Object iTextSharp.text.pdf.pdfreader -ArgumentList $fileInfo.FullName | |
| $doc.AcroFields.Fields.Keys | % { New-Object PSObject -Property @{ Key = $_ ; Value = $doc.AcroFields.GetField($_) } } | ? Value | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment