PowerShell Module to convert PSObjects to formatted Html (targeted to Outlook)
From PowerShell run:
Register-PSRepository -Name converttohtml -SourceLocation https://ci.appveyor.com/nuget/converttohtml
Install-Module converttohtml -Scope CurrentUser
- Download nuget.exe from NuGet.org
- &nuget.exe install ConvertToHtml -source https://ci.appveyor.com/nuget/converttohtml -outputDirectory "$env:USERPROFILE\Documents\WindowsPowerShell\Modules" -ExcludeVersion
If you make changes, please run the pester tests, and run these two tests:
Get-Process | ConvertTo-FormattedHtml -OutClipboard
paste the results into outlook and verified they are formatted correctly
dir| Select-Object Mode, lastwritetime, length, Name | ConvertTo-FormattedHtml -OutClipboard
paste the results into outlook and verified they are formatted correctly
For HTML to work in Outlook 2013 and older, only inline styles can be used.