htmlViewText Property

       

Returns or sets a String that represents the HTML view text for the current document. Read/write.

expression.htmlViewText

expression   Required. An expression that returns one of the objects in the Applies To list.

Example

The following example prints out the HTML view text in the Immediate window. The following example assumes that the user is in HTML view.

Sub HTMLViewtext()
'Displays the HTML view text

    Dim objApp As FrontPage.Application
    Dim objDoc As DispFPHTMLDocument
    Set objApp = FrontPage.Application
    Set objDoc = objApp.ActiveDocument
    'Display view text in immediate window
    Debug.Print objDoc.htmlViewtext

End Sub