In my Word document, I would like to replace some placeholders with .jpeg files. However, they are taking up a lot of space, so I thought I would convert them to .webp files and insert them into my word document. After converting those .jpeg files to webp using Aspose.Imaging, I get an error when I try to replace placeholders in my word document with those webp files. I used code form this ticket in order to do that Replacing text placeholder "<<Logo>>"
with an image - Free Support Forum - aspose.com, but it seems it doesn’t recognize webp files. I didn’t see any image device in aspose.words and i get an error that says it doesn’t recognize a bitmap…
e.g.
builder.InsertImage(imageFile, RelativeHorizontalPosition.Margin, 0, RelativeVerticalPosition.Margin, 0, 495, 742, WrapType.Through);
builder.InsertBreak(BreakType.SectionBreakNewPage); //image file is of type .webp