IHTMLImgElement Object

Microsoft FrontPage Visual Basic

IHTMLImgElement Object

IHTMLImgElement

Represents an individual IMG element in an HTML document. The IHTMLImgElement object provides access to a limited number of properties and methods related to the IMG element. For access to all properties and methods, use the FPHTMLImg object.

Using the IHTMLImgElement Object

Use the images property to return an IHTMLElementCollection collection that represents a collection of all the IMG elements in a document. Use the Item method to return an FPHTMLImg object that accesses a specific IMG element, referenced by ordinal number or by the value of the id attribute. The following example accesses the first IMG element in the active document.

    Dim objImage As IHTMLImgElement

Set objImage = ActiveDocument.images.Item(0)