iainbrighton/PScribo

Add Image as Base64

itamartz opened this issue · 14 comments

I saw in the about_plugin that Image is supported in Base64String.
Can you share an Example on how to add Image to a document?

Tnx

Itamar

@iainbrighton An example would be really helpful if you have time. Cheers. M

@itamartz @mc1903 I have now published the image support to the dev branch and see the example here. Feel free to download the dev version and have a play (it's not yet in the published module/master branch)

@itamartz I can't see what error you are getting. Can you post the error and what Windows/PowerShell versions you are using?

@itamartz Strange - This is on a fresh Windows 1709 build, downloaded dev branch:

PS C:\Users\Iain\Documents\WindowsPowerShell\Modules\PScribo> $PSVersionTable

Name                           Value
----                           -----
PSVersion                      5.1.16299.1004
PSEdition                      Desktop
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}
BuildVersion                   10.0.16299.1004
CLRVersion                     4.0.30319.42000
WSManStackVersion              3.0
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1

PS C:\Users\Iain\Documents\WindowsPowerShell\Modules\PScribo> .\Examples\Example31.ps1 -PassThru

    Directory: C:\Users\Iain\Desktop


Mode                LastWriteTime         Length Name
----                -------------         ------ ----
-a----       02/05/2019     14:51         114821 PScribo Example 31.docx

PS C:\Users\Iain\Documents\WindowsPowerShell\Modules\PScribo>

It is patched, but I will try an unpatched 1709 build and see what happens..

Wierd. Works in a stock 1709 build in the ISE too:

image

Hi @itamartz are you still struggling with this? I can open the file and run it successfully from the ISE on Win10 1909 x64 too

OK. Please feel free to reopen the issue if you still have problems (v0.7.26 has been published to the PSGallery)