ShapeBaseIsImage Property
Returns true if this shape is an image shape.

Namespace: Aspose.Words.Drawing
Assembly: Aspose.Words (in Aspose.Words.dll) Version: 20.1
public bool IsImage { get; }

Property Value

Type: Boolean
Opens an HTML document with images from a stream using a base URI.
Document doc = new Document();
// We are opening this HTML file:      
//    <html>
//    <body>
//    <p>Simple file.</p>
//    <p><img src="Aspose.Words.gif" width="80" height="60"></p>
//    </body>
//    </html>
string fileName = MyDir + "Document.OpenFromStreamWithBaseUri.html";
// Open the stream
using (Stream stream = File.OpenRead(fileName))
    // Open the document. Note the Document constructor detects HTML format automatically
    // Pass the URI of the base folder so any images with relative URIs in the HTML document can be found
    LoadOptions loadOptions = new LoadOptions();
    loadOptions.BaseUri = ImageDir;

    doc = new Document(stream, loadOptions);

// Save in the DOC format
doc.Save(ArtifactsDir + "Document.OpenFromStreamWithBaseUri.doc");
See Also