cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Knives26
Regular Visitor

The image is not of type PNG or JPG. Please provide an image of type PNG or JPG. Sharepoint image to word template

Hi,

 

I have searched in all of the threads I have seen relating to this error and I cannot find an answer which helps me.

 

I am trying to populate an image in a word template and am getting the error: 'The image is not of type PNG or JPG. Please provide an image of type PNG or JPG.'

 

I have an array variable which I am initializing with no value:

Knives26_1-1651250601563.png

 

I am then getting the file content from sharepoint (Where these images are stored) and the setting the variable to that:

Knives26_2-1651250650575.png

Where it states that the image is a JPEG file (Which on other threads I have seen people say works fine).

 

Then when I try to put it into my template I get the error:

Knives26_3-1651250792677.png

I'm not sure how to fix this error, any help would be much appreciated!

2 ACCEPTED SOLUTIONS

Accepted Solutions
v-bofeng-msft
Community Support
Community Support

Hi @Knives26 ,

 

The point is that the variable is an array but the image control can only allow input one picture. As a workaround , I suggest you use 'first' to get the fist item as the parameter.

vbofengmsft_0-1651470829710.png

 

Best Regards,

Bof

 

View solution in original post

Thank you!

 

To fix this I just changed the variable to be an object instead of an array and that fixed it as well.

View solution in original post

2 REPLIES 2
v-bofeng-msft
Community Support
Community Support

Hi @Knives26 ,

 

The point is that the variable is an array but the image control can only allow input one picture. As a workaround , I suggest you use 'first' to get the fist item as the parameter.

vbofengmsft_0-1651470829710.png

 

Best Regards,

Bof

 

Thank you!

 

To fix this I just changed the variable to be an object instead of an array and that fixed it as well.

Helpful resources

Announcements
Power Automate News & Announcements

Power Automate News & Announcements

Keep up to date with current events and community announcements in the Power Automate community.

Power Automate Community Blog

Power Automate Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Users online (4,564)